Around 20,000 Ukrainians are to be put through an intensive five-week course to help them prepare for combat.
His Majesty watched as the men - mostly civilians - stormed a mock trench.
"We're trying to get them to learn how to use the ground to their advantage," said Capt Freddie Bradshaw from 1 Irish Guards.
"We've got urban and trench complexes which they can use. They need to learn how to fight in a forest - a lot of Ukraine is forest.
"There's a huge amount of experience from the training teams here.
"We are trying to make them as lethal as possible in a short space of time - five weeks is a very condensed training package," he said.
One Ukrainian soldier told the BBC: "It's an amazing feeling to be in the presence of His Majesty.
"It's been the event that most light will shine upon my life.
Another one said: "He asked how training was going, and our health, and took an interest in the wellbeing of our families and wives.
"I feel light on my feet and I think it will sink in a few days later," he said.