In all co-op modes (story, and adventure), there can only be one colony, and everyone is automatically teamed.
In vs mode, there is a set amount of teams when the server is created, and each team can have their own colony. You choose which team to be on before entering the server.
In Survival mode, everyone can create their own colony, and no one is teamed. You can create a team in survival mode, but it is pointless, because you do not share the colony with each other. Only the creator of the colony can access the machines.