In the past week, Mr. Trump has dismissed the North’s recent short-range missile tests with a shrug, saying they involved neither a nuclear weapon nor intercontinental ballistic missile. Instead, he accused South Korea of not paying enough for American help in defending itself from North Korea.

“We get virtually nothing,” Mr. Trump told reporters on Wednesday. “And South Korea and I have made a deal where they’re paying a lot more money, and they’re going to pay a lot more money. And the relationship is a very good one.”

On Friday, Mr. Trump again said he had never supported the exercises with South Korea.

“I’ve never liked it. I’ve never been a fan,” he said. “You know why? I don’t like paying for it. We should be reimbursed for it, and I’ve told that to South Korea.”

Over the years, South Korea has gradually increased its share of the cost of maintaining an American military presence on its soil. South Korea paid about $925 million this year, but Washington wants it to pay more. The allies are about to begin a new round of talks on how to divide the cost for next year. Currently, 28,500 American troops are based in South Korea.

Analysts suggested that North Korea was using Mr. Trump’s preoccupation with cost-sharing to sow discord. Last month, North Korea warned that if the United States and the South did not cancel the joint drills, it might scuttle efforts to resume negotiations with Washington and even restart nuclear and long-range missile tests.

”Breaking the alliance is exactly what Pyongyang wants, which is why it makes all this noise and tries to blame U.S.-South Korea drills for its lack of cooperation,” said Leif-Eric Easley, an associate professor of international studies at Ewha Womans University in Seoul. “Kim appeals to Trump directly about the exercises, trying to drive a wedge between Washington and Seoul.”

Since last year, Mr. Trump has held three summit meetings with Mr. Kim, including a brief meeting on the South Korea-North Korea border on June 30. But he is nowhere near close to depriving the North of its nuclear weapons.