Actually, the competition is largely in your head, not in academia itself.
I'll never be able to win a stage of le Tour de France, so why should I ride a bicycle? I'll never win the final at Wimbledon, so why should I play tennis?
Of course, there are extremely competitive corners in academia. If you are in a "hot" research area where many many people are chasing exactly the same very few goals, then, yes, you are likely to get scooped.
But imagine two scenarios.
The first is that you have a thousand people at one end of a field and there is a single prize at the other end. Everyone runs to get that prize but only one can succeed.
The second scenario is that the thousand people are wandering around the field, each seeking something that they find interesting. Here, everyone can succeed.
Academia is, except in a few instances, much more like the second scenario than the first. Collaboration is possible. Two can enjoy a sunset. But only one can capture the flag.
Another competitive scenario is being one of many junior faculty at a very (very) top university, in which only one can be promoted to a tenured position. It is, of course, very competitive and collaboration with your competitors may be sub-optimal. But collaboration, even here, with others is not to be spurned. Even being second or third on an important paper is a good thing for a beginning academic, so long as you don't quit with just that.
But most universities, even very good ones in the US, aren't like that at all. Life can be good. But there are also some people who thrive in such a high pressure environment and would have nothing else.
My experience in academia was that the greatest thing was that I could think my own thoughts and pursue my own goals. Much of that was in collaboration with people. Some of those folks were just about like me, and some were internationally known superstars. But it was always fun.
I studied at R1 universities, but taught there only briefly (visitor). But my sense of it was that even for people in the same narrow field, collaboration was highly valued. The most senior professors, were happy to share ideas with junior faculty in field-centric seminars. Often those junior faculty (and we grad students) would develop those ideas, even with help of the top researcher. It was a shared process to extend what was known.
Of course, if a person has a lot of ideas, it is also often the case that they don't have time to completely explore them. For such people, generosity in sharing those ideas costs them nothing. They may not be a co-author of every paper, but their stature in academia rises nevertheless.
Don't think of academic, or research in general, as a zero-sum game. Everyone can win, especially if everyone has their own goals and are not somehow driven to adopt the goal/value system of others.
The field of research is broad and richly endowed. Find the bits that are interesting to you.