Ads aren't the problem. Ad companies go out of their way to ensure their ads don't exceed the cultural average in terms of content and messaging. The problem with social media is the content kids are being fed. Communicating with their friends isn't the problem, its that they are consuming content not just from their friends, and their friends are also being influenced by content outside of their social bubble. It's the wide connectivity and the foreign ideologies that come with it.
I think it's more specific than that. You're right that the advertiser using the platform to target an ad isn't exclusively problematic. Also problematic is the person who uses the platform in a targeted way to shape the global narrative according to some agenda they have. There's something antisocial about seeking influence over people who don't know you.
In some sense perhaps the attention economy that arises from this scenario is inescapable. But we have a lot of gray area between whether we make it something to be encouraged or whether we make it something to be mitigated.
If I had kids, I'd rather they use social media that aims to connect people with their friends without giving anyone a megaphone or a lever to influence the big picture narratives in flux at any given moment. As far as I'm aware, such media are in short supply. And as software folk it is we who should be doing the supplying.