For legacy companies yes but it would be very hard for new YC companies or existing non-mainframe companies to create a spreadsheet showing how buying a new IBM Z mainframe would cost less than the latest commodity x86 or ARM servers in the cloud or on-premise.
The IBM pricing for mainframes makes sense for legacy companies like banks and airlines with a million lines of old COBOL code that want to keep it all running with the latest chip technology. (The mainframes from a few years ago are coming off the lease and they need to upgrade to whatever new mainframe IBM is offering and sign another lease & service contract.) So, IBM mainframe prices are very expensive -- but legacy companies will pay it because migrating the code away from mainframes can be even more expensive.
It's similar to expensive enterprise pricing of Oracle, Embarcadero Delphi, Broadcom etc that takes advantage of existing customers already locked into their products. Virtually no new tech startup with a greenfield project is going to pay Delphi $1599-per-seat for each of their developers. Only existing customers stuck with their investment in Delphi code are going to pay that. (https://www.embarcadero.com/app-development-tools-store/delp...)
But some companies do endure the costs of migration to get out from IBM lock-in. There are lots of case studies of companies shifting their workload from mainframes to AWS/GCP/Azure. I can't think of a notable company that did the reverse. Even a mainframe hardware vendor like Fujitsu quit making mainframes and shifted to x86 running an emulation of their mainframe os.
Yes, IBM mainframe can run other workloads besides COBOL like Java and C/C++ but no company that's not already using mainframes would buy & deploy to IBM's Z hardware for that purpose.