Colonization contributed to civil wars in a couple of major ways.
First, colonization caused relatively artificial lines to be drawn -- countries' borders were drawn based on where the colonizers wanted them to be. What often ensued was that various ethnic groups were lumped together in one country even though they did not want to be. In addition, the same ethnic group could be split between a number of countries. Both of these things made for conflict.
Second, the colonizers often favored one ethnic group over the others. That led to hatred or jealousy along ethnic lines.
These factors caused civil wars to be much more likely in newly-independent African countries.