First there was the family, Mother and her children. Then in some cultures the dad and other relatives became part of the extended family. This got larger and became a tribe. Many tribes merged into a clan. Then things got complicated, some tribes and clans merged into nations. Other tribes formed cities. The large cities conquered surrounding territory and became city states, often with extensive territories, empires.
Eventually modern nations, with subdivisions called states, provinces, counties and cities evolved. Unfortunately the boundaries of these subdivisions have become in many ways obsolete. Cities on opposite banks of a river may be in different states, but have more in common with one another than they do with their home state. Suburban residents outside a city may make more use of some city services: libraries, museums, colleges than residents within. Some cities require critical employees to live within, even though this may be a financial or cultural hardship. It may deprive the city of the best candidate for some jobs, like teachers and police officers.
Many cities have learned to blur the lines to improve services. Port districts manage the entire waterfront of multiple cities. Many utilities are based on topographic boundaries rather than political, and some school districts are based on demographic boundaries. Regional transportation has largely replaced municipal.
Unfortunately some cities, like Detroit, appear to be locked into the city state mentality and try to be everything to everyone within the arbitrary (historic) boundary, while at the same time supporting services that benefit non-residents more than taxpayers. With today’s information technology there is no reason for all city services to have the same boundaries. A separate service district for each service can be designed and managed to maximize efficiency, within much larger boundaries, such as county or state. This of course might make mayors and city councils obsolete, but I can live with that.