Yes, management consultancies are not hired because anyone expects them to know what they're doing.
But they are hired for a certain specific kind of "expertise" they uniquely possess — that being the internal knowledge about management decisions being made in other companies (perhaps with their guidance; or perhaps just with them there at the time to witness those decisions.)
In other words, management consultancies can tell you how to "copy the success" of companies you personally think are worth copying, provided the management consultancy you hire has records of their consultants working at that company. (You won't actually be "copying their success", because you'll be applying your mental schema of what would make for success to deciding which of their internal practices and decisions should be copied. So it's more a "cargo-culting of success." But executives still want that!)
A CEO won't trust the thinking of a fresh 20-year-old sent over by Bain. But they will trust the thinking of a CEO they admire. And they're willing to pay big bucks just for Bain to send them the 20-year-old rather than Bain's best, not only because the 20-year-old is a political tool; but also because the 20-year-old is a channel through which the CEO can tap into Bain's institutional memory of private leadership meetings held by their most-admired CEOs!
(And this creates an active transmission vector for the spread of business-management-theory memes. "Return To Office"? It may have started because a few bigcorps like Apple had big albatross investments of commercial real-estate in the form of massive HQ buildings. But it spread throughout the Fortune 500 via their shared reliance on the management-consultancy grapevine.)
Management consultancies know that this is half the reason companies hire them — or at least the consultants who've been around the block know this. And this is why there's any place at all for senior management consultants, rather than it being strictly a "get in, make your money, retire early" sort of job. It's not that the senior consultants know more about business. It's that their field experience has enabled them to internalize and distill the current corporate zeitgeist — and so they can just tell you off the top of their heads what you should be doing to be the management-theory equivalent of "fashionable." (And this doesn't look outwardly any different than the "best practices" advice the 20-year-old will give you based on what they learned in their MBA program. So there's plausible deniability in this, in a way there isn't in asking the 20-year-old to dredge up records from your competitors.)