This has always puzzeled me. What is the real purpose of this?
Historically cities were chartered. They were a form of private property, owned by associations of merchants or somesuch. (The City of London is still administered by businesses; it was never expropriated in its history.)
If your question is why someone would do that at all, it is in order to produce shared goods like streets or city walls.
In the words of Marc Stevens, “Cities and States don’t exist.”
In feudalibertarian bizarro world they are.
He is obviously wrong.