XP, and several other processes, identify the problem as a mismatch between the goals of the developer and the actual customer (not necessarily the end user). Management doesn’t figure prominently in the solution which is probably one reason why a different form of Agile is usually chosen. I also don’t know why businesses are so reluctant to have their customers involved in software development. But you’re definitely right, when all the incentives align on the axis of management and their needs, you get garbage.
This is not to say that management isn’t useful or necessary, but they are a facilitator of work, not the patron.