They sell (managed) database appliances (on z and Power) and associated software (think the platform/HANA parts of SAP) - all state-of-the-art in the late 1990s but since then put on maintenance mode and it shows (a bit like oracle...). Their hardware is still cool custom built silicon and imo state of the art, but since k8s, high-speed-network and multi-TB-machines (for <100k$) are here and run Linux no new venture buys into that anymore (except for gulf states...). Before, when the competition was a cluster of Itanium/VMS or Sparc/Solaris and the associated contract, noone bought into that either at scale but also noone using IBM had a very compelling reason to switch everything around.
So essentially they sell new hardware and "support" to customers who have been in need to process tabular, multi-GB databases since when a PC was 128MB memory and have been doing electronic record-keeping since the 1970s. They also allow their ~hostages~, ehm, customers who trust them with their data to run processing near the data at a cost/in a cloud style billing model. That is so expensive though that every large IBM-shop has built an elaborate layer of JVMs, Unix and mirror-databases around their IBM appliances. Lately they bought Redhat and hashicorp and confluent thus taking a cut from the "support" of the abominiations of IT systems they helped birth for some more time to come (also remember the alternative JVM OpenJ9, do you all?).
I think the later a company started using centralized electronic record keeping, the higher the likelyhood they are not paying IBM anymore: commercial banks, governments and insurance started digitizing in the 60s (with custom software) and if the companies are old (or in US-friendly petrostates) they are all IBM customers. Corps using ERP or PLM offerings (so manufacturing and retail chains which are younger than banks) used to start digitizing a little later (Walmart only was founded in the 60s and electronic CAD started in the 80s) and while they likely used IBM in the past (SAP was big on DB2) they might not use it anymore (also it helps they usually bought the ERP or PLM from someone else). New Companies whose sole business was to run a digital-platform started on Unix (see Amazon who successfully fought to ditch Oracle even) or just built their whole platform (Google). If those companies predate Unix they usually fought hard to get rid of IBM (Microsoft, Amadeus)
Consulting/outsourcing services have been spun out to Kyndryl, so nowadays IBM only sells hardware, support for their products and ostensibly has some people left to develop their products... The days when that was a big thing and IBM produced all the stuff they sell support for now, have been long gone. A fun link to see how their "product development" operates nowadays is this discussion to bring gitlab-runners to z/OS: https://gitlab.com/gitlab-org/gitlab-runner/-/work_items/275... - tl;dr "hey you opensource company, we are IBM and managed to pay someone to port a go compiler to z/OS. Now we have a customer who wants to use gitlab with z/OS. Would you like to make your software part of our product offering?". A fun fact is that - even within IBM - access to the real mainframe seems to be very limited which shows a bit in the discussion linked above and also with an ex-Kyndryl-person saying: "oh, I once had a contract where we replaced the mainframe and we ran that on Linux-boxes inside IBM, because it was just cheaper that way. Just the big reporting was a bit slow, but the reliability was just fine"