Not sure if they're explicitly sharing data, but there does seem to be something that's sharing data across the platforms. When I buy something from Tiktok, the ads for the same thing shows up on my instagram almost instantly. Doesn't necessarily mean they're directly sharing data of course, could be a third party too. But as a consumer that has very little difference for me.
If you buy something from Tiktok, you presumably visit the merchant's website, which almost surely will have chosen to have a tracking pixel that sends data to FB (Instagram). You can read a bit about how tracking pixels work here: https://jvns.ca/blog/how-tracking-pixels-work/
In this case it's not Tiktok and Instagram that are sharing data with each other, but the product website that is choosing to share data with both of them.
It's because you are the exact target demographic consumer for that product, and it's visible in your behavior patterns when using your apps combined with what they know about you (age, sex, location, demographics, etc.)
Much more likely an explicit retargeting ad network that doesn't realise they already bought it.
Retargeting has been a thing for like 15 plus years now. Visit website for knives, ad network tracking cookie notes that down, same ad network later serves you ads for the same knives. Or some convoluted data sharing network that has the same outcome these days.
It's not much more likely. People don't realize but demographic targeting works really well. When you are a certain age, certain gender, living in a certain area, with a few other inferred characteristics, you're very likely to be talking about, thinking about, and buying a small set of product types
I think the OP knows best what happened to them, so I will leave it up to them to decide. But to get targeted for a product you just looked feels like pretty standard retargetting.
I don't disagree with your point that demographics can be very good and sometimes uncanny, that aspect I agree with. It is just the timing that leads me to believe it is retargetting.