They offer reputation. Career advancement is highly dependent on publication history and impact. Getting into a prestigious publication means your work will more likely be read and cited. Because highly reputable journals can charge high publication fees (because it’s in such high demand), they get to set the industry norm, which other less reputable journals/publishers get to follow. It does cost money to develop and maintain that reputation for rigour and impact (i.e. good science). But yeah it’s exploitative AF. There are attempts for less profit-motivated publications… But making those rigorous while still being democratic is hard
All this has happened before, and all this will happen again.