Because human beings want it to. They like the formal, official, status of the relationship, the public commitment it represents.
Children like it, too. They tend to prefer that their parents be officially married. It makes them feel more secure.
Even where standard formal marriage is becoming less popular (as in some European countries), people are still opting for some sort of official status, which is often temporary (renewable), but people still choose it.