A man in a military uniform is walking away from a line of military vehicles.
A military man is walking away from the line of military vehicles
"A man in a military " is a rephrasing of "A military man "
a man in a military uniform implies he is a military man.
a military man is normally seen in a military uniform.