Communism is a post-socialist mode of production established by resolving the contradictions within socialism. States eradicate themselves by eradicating the basis of class, and this happens by collectivizing production and distribution.
The contradictions within socialism will not be resolved without people acting on their own initiative to resolve them. The state siezing the means of production and claiming it is doing so on behalf of the people forms a new basis of class, it does not eliminate it. It is simply taking the means of production from one set of private hands to another more centralized set that is only somewhat more responsive to the people's will. The people must act of their own initiative to forcibly decentralize the power of the state until no hierarchy remains in order to eliminate class.
Cooperatives are petty bourgeois collectives of private property, not socialist property. The idea of competing small cells of worker-owners is petty bourgeois in origin and stands opposed to collectivized production and distribution.
Who says they have to compete? Realistically they would form federations to organize production and distribution on larger scales. Cooperatives in Italy do this, though they face strong resistance from corporations and the state as they do so. If you have eaten Parmigiano Reggiano you have eaten something created by many small cooperatives banding together to collectivize production and distribution. The cheese is made with milk from many small cooperatively owned farms that pool their resources together and share in the profits.