Suppose there is enough on-street parking for other non-residential uses. You don't want these spaces being constantly used by car owners who are living in apartment complexes that aren't meant for them. As a local government, you have to play the game of not letting them park using parking restrictions while potentially also managing by-laws that allow residents to get parking permits that let them bypass some restrictions.
This doesn't really apply in high-density urban areas, but I could see it being tricky to manage in growing areas.
(Although, I guess from a non car-owner's point of view you wouldn't care about whether other drivers are being inconvenienced by a lack of parking, because the knock-on effects wouldn't affect you.)
It's just as bonkers for a city to shut out everyone who can't use transit.
When the government forces all developers to build parking, and provides free or severely underpriced parking on streets, it lowers the market value of off-street parking. Developers are forced to price-in parking development and maintenance.
Developers will still build parking where residents need parking. If they didn't, they would have trouble selling/renting their property. There is no need to force them. In cities around the world, we still find private parking in absence of parking minimums.