I feel like it's a self-fulfilling prophecy. "What do little girls like? I heard they like tea parties! Well then, as a little girl, I guess I should throw a tea party."
I don't think I knew that such a thing existed until much later in life, maybe at six. By then I was too old for the baby stuff.
Sure I had tea parties. I loved them.
Except I drank actual tea, not warm water. And I had them with my friends and my little brother, not with dolls and stuffed animals. We would sit around pretending we were having "a propah English tea pahty," and speaking with terribly posh accents interrupted by the worst table manners imaginable, from slurps to burps.
My parents were never involved.
They probably would have banned them if they knew how badly we behaved.
As for how it got started, some church lady I never met sent me a porcelain tea set. We were poor, so churches would send us food and clothes.
It was fun, though I couldn't tell you what the appeal was. Maybe it just seemed like a "grown-up" thing to do.
But then that is how they are marketed too.
Little girls aren't born knowing about tea parties or preferring them to monster trucks. They learn from their parents, friends, media, and toys what things are considered to be acceptable and fun play for them.
But then I think it is less common today. I see my little girls playing with cars as much as little boys and as many little boys pretending to be dads while playing dolls. I've never seen a tea party happen, but they do all enjoy playing in the kitchen and acting as a family doing domestic things. Which I find better.