Does the journal pay for the academics’ time in reviewing articles? No. Does it pay for the articles themselves? Also no. What service, exactly, is the university paying all that money for?
It seems to me that the core service journals offer is as a central place for people to submit articles. And some organisation around requesting and collecting reviews.
And that sounds like the sort of thing you could replace with a website. The workflows we use for modern software development (eg on GitHub) are far more complex, maximally automated and free. And the result is source code anyone can browse, without needing any of the code to have its copyright handed over to a rent seeking middleman.
It’s crazy that academics of all people live in such a primitive ecosystem.