I believe that they are black because black color is the best radiator of heat. Tyres heat up a lot when they roll because of the impact they experience as they hit the road, expansion and contraction of the gases in the tyres and friction between the tyre and the road.
If the tyres were any other color, say white then it will retain more heat which could damage the tyre. Probably melt it or cause it to explode because of the expansion of the gas as it is being heated. Even if it did not explode, the high temperature is not good for the tyre as it promotes wear and tear.