Isolation provided by transformers
Your question is one I had, as well. It seemed that a lot of people I'd heard about (back in the day before there were any additional protection circuitry in a home) were hurt or even killed on occasion just touching one conductor and where a transformer would seem to have helped. More, you often read where engineers say you should ADD a transformer for your own protection from shock events. So, when I was learning about these things those questions came up for me, too.

(Keep in mind, too, that these decisions to ground homes and to ground local distribution power transformers were made LONG before there was anything like GFCI or AFCI protection circuitry available. So the primary reasons for using an earthen grounding approach can't include those devices as justification, since they didn't exist when these decisions were being made. And if new devices are instead said to be important, then perhaps the original decisions for earthen grounding systems may no longer be valid and the explanation may fall on that point, as well.)

Consider weather situations such as when storms and lightning are taking place outside. There are huge build-ups of charge going on and these aren't just in the air, but also in the ground from one side of a piece of land to another. A power transformer might be located off your property (elsewhere) with conductors running inside of insulation to your home some distance away, but floating at quite some different voltage from the nearby ground at your home. Or a lightning strike might highly energize something in your home. So you could experience not hundreds... but perhaps thousands... of volts and this could drive a lot more current through your body than if you'd had things "tied down" to the local Earth. (A similar situation might arise with large static charges built up inside of equipment you operate using the power system, too.)

Now, if the decision is taken to use earthen grounding systems and to stake (or use a Ufer grounding system: concrete and rebar in the foundation) the electrical system to ground near the home and to do the same for various nearby homes as well as for the local distribution transformers, then there are very good conductors tying all this into very low impedance net. It will be almost all at very similar voltages, too, because of that. And while there is a large capacity for storing charge in the earth, because of everything being tied together with conductors those things near the conductors will be nearer to similar potentials, too. Charge differentials won't sufficiently accumulate to create large voltages between them, because they are grounded and will bleed that charge out into the larger system. Lightning strikes will move charge into the local earth. But the whole system moves with that, too.

Sure, there's a trade-off of sorts. Grounding everything to earth means that you could be standing in a puddle of water and be half-connected into the system. So yes, touching the hot conductor of the power system could shock you. But the risks of not doing that may be still worse and more likely. It also makes each home's situation more predictable and manageable for those who will then go on to design equipment you may use, as well.

Since then, of course, there are newer ground fault and arc fault protection devices available. So the entire situation is now so much, much better. Plus, the advantages of earthen grounding, as well.

Bear in mind, I'm just a hobbyist in all this and my opinion here is a matter of reading the writing of others. I'm not a trained electrician and don't have an independent, well-informed opinion on this subject. So consider what I've written and then look things up for yourself. I think your question is an important one. Enough so that you should think for yourself and read what you can find about it. But that's my take on it. I hope that helps.