It could simply be that black paint is cheaper... But I believe that the external coils on the back of refrigerators are painted black for the following reason: There is a rule in nature that says "a color that is better at absorbing heat is also better at radiating heat." Here is how Encyclopedia Britannica puts it:
Since black is a good heat-absorbing color, it is also a good heat-radiating color. One of the things the external coils do is radiate heat, so they are painted black to help that process.
Here are some interesting links: