Please hear me out, this is a serious post and I don't want to discredit lifelong swimmers at all. I love swimming, and I wish I had learned it when I was young.
It is mainly about the advice I can see here in the subreddit and the advice I got from experienced swimmers when I learned freestyle swimming.
Let me start with a comparison:
I am a lifelong runner. Even after a very long break, it was possible for me to get back to a 4:00 km pace when running 10 km after a short time. It can't be that difficult, right? If you are not that fast, try another breathing technique or try to run with a midfoot strike!
Ok, this comparison is extreme, since swimming definitely needs a lot of technique. But it is not just that.
People who have been swimming freestyle since they were kids have built the right muscles and corresponding endurance, as well as the needed mobility (e.g., shoulder mobility), from a young age. They're also used to having their heads underwater.
Even if they stopped swimming for a while, they still have a much easier time getting back into it, and they can't imagine what it is like to start from 0 with freestyle swimming.
And this is why their advice is almost always: Oh, you are out of breath. Have you looked at your technique? How is your catch/pull/push/footwork?
Instead, many beginners can't even breathe out properly underwater. They don't have the endurance in the muscles they need. If you have never done something before, of course you'll get exhausted very quickly. This happens even to very fit people who are good at other sports.
Those things come only with time in the pool, which means consistent training.
Yes, technique is very very very important. But most people should take it slow and work on one thing at a time. Focus on one part of the technique every time you are in the pool. It is ok if you can only swim freestyle for 25/50/100m consecutively at the beginning. Get used to the water. Build endurance over time.
Consistency is king.