The most important word in the definition is real. Somatisation does not mean you are inventing it, exaggerating, or that it is "all in your head". The pain is present, measurable in behaviour, and hurts exactly as much as you say it does.
The mechanism is physiological. Prolonged stress maintains muscle tension, alters gut motility through the gut-brain axis, raises pain sensitivity and disrupts sleep — which in turn amplifies pain. Nothing in that chain is imaginary.
It is especially common where psychological distress is stigmatised. When "my stomach hurts" is an acceptable sentence and "I'm depressed" is not, the body becomes the available channel. That is why somatisation is reported more often where the mental-health conversation is harder — not because people there suffer differently.