MOSCOW — Ukraine’s president, Petro O. Poroshenko, said Tuesday that he and President Vladimir V. Putin of Russia “seemed” to have agreed on a high-profile prisoner exchange that would bring home a Ukrainian officer now in Russian custody.

At a news conference in Kiev, Mr. Poroshenko said he had called Mr. Putin to discuss the matter, and that “it seemed to me that we succeeded in agreeing” on the swap, which would repatriate two Russian soldiers that Ukraine recently convicted on terrorism charges.

Analysts cautioned that the deal could still hit a snag over perhaps the most critical issue of the war in Ukraine: Russia’s insistence that its regular army has never been involved in the fighting there.

Given that stance, the trade poses a dilemma for Mr. Putin: Accepting a swap for a Ukrainian officer would get the pair home, but might also amount to a tacit admission of the Russians’ status as soldiers.