Yes, the current defense mechanic for cities (improved attack, defense and initiative for each unit, as well as free militia and archers) seems a bit contrived to me.
It is a mechanism to simulate the difficulty in breaching a defenders' walls without dragging out the battle, but it currently creates some ludicrous side-effects (such as a "naked" militia unit dealing hundreds of damage points with clubs, yet folding from one hit by your high trained troops).
I think that walls could be implemented that do not interrupt the pace of tactical combat but provide substantial defender bonuses that do not seem so contrived. For example: a city tactical battle has unscalable walls that have two, one-tile openings initially covered by a door. Archers and other ranged units can fire over the walls, but melee units must run up to the doors and break them down to get in. The doors serve as suitable choke-points (for the defenders to use to their advantage) but do not slow down combat to a crawl since they will be relatively "flimsy."