Of course doing lots of collaborations doesn't imply you're a better scientist. It just means you're better at networking.
While you're right that merely doing collaborations doesn't make you a good scientist, they're still good they let you work with people from outside your little circle. Being the biggest fish in a small pond doesn't make you a fish of any stature in a large lake. If you've got something or done some work with genuine widespread impact, working with others — collaborating — is a good way to maximise that impact. It can also help you take techniques from one area and apply them to another where the practitioners within either of those two areas would not normally communicate at all.
For example, I've done things taking techniques for computation for solar physics and applying them to biodiversity and computer-aided physiology. Those are areas where the scientists within them do not normally collaborate; they don't feel they have much in common at all. But computer science most certainly can cross over between these areas, and very usefully.