I believe cities were originally founded for mutual protection from raiders. Obviously, that’s not an issue today.
I can tell you why I choose to live in cities. It’s for the interaction with multiple people and the wonderful things they can build. A forest can be peaceful and beautiful, but there is no art or theater in it.
I think that the way to make cities better for the environment is to make them more dense, using the buildings that already exist. Many cities like mine have a semi-vacant core. If people lived closer together, biking, walking and public transit would be more feasible as forms of transportation. City dwellers usually have a much smaller environmental footprint than suburban dwellers, for example. I think it’s sprawl that’s really unsustainable.