It was not the military that separated the races in WWII. It was Woodrow Wilson in WWI who put back into place the division of races in the military. Even with that, many blacks served in Europe in the first war.
Many blacks served in WWII in both theaters of war in all of the services. Montfort Marines, Tuskegee Airmen, any of those ring a bell?
Black soldiers were segregated before Wilson, in the old regular army they had separate “colored” regiments.
What the US did in WWI was to create similarly segregated regiments, brigades and divisions. These were committed to battle as any other unit, and indeed the 369th Regiment “Harlem Hellfighters” ultimately had more time on the front line than any other.
The situation was actually worse in WWII. They again had segregated units, but by then there was a reluctance to deploy black combat units. Only one black division (92nd) was committed to combat at all (Italy, 1945, with poor results). There were a few black tank, antitank, engineer and artillery battalions used in combat, but these were considered acceptable because they were specialists and so consisted of picked men.