The commander-in-chief can wear whatever he chooses. He could probably wear a military style uniform if he wanted, but he is still a civilian, and, as such, no rank. He is what is known as civilian in control of the military.