Milley had no authority to conduct foreign policy without the president's knowledge and backing. That's the bottom line and telling a foreign power our military plans certainly falls under that umbrella.Rudy wasn't in charge of anything. Milley was in charge of the armed forces talking to a guy who was in charge of someone else's armed forces.
If Trump had no intention of starting a war with China, then Milley assuring the Chinese that we weren't going to attack them doesn't seem that far out of line.
Of course, Trump really looked like he was getting ready to attempt a coup, firing top officials, inciting riots, so the Chinese maybe had a legitimate reason to be concerned.