Onions are plant-animal creatures just like Pikmin, they serve both as a home for Pikmin as well as their main way of reproduction, having a role similar to that of an ant queen, when grounded they'll suck up nearby dropped pellets and crystalized nectar, and use their nutrients to produce Pikmin seeds of their same color. Onions are also capable of storing an almost unlimited amount of Pikmin, keeping them safe from danger, and even being able to take the fly and move around with them.

Onions are a central part of Pikmin production and management, so you'll need to learn where to find them and how to control them.