KYIV, Ukraine — When Rudolph W. Giuliani met with a top aide to Ukraine’s president last summer, he discussed the prospect of a coveted White House meeting for the president while seeking Ukraine’s commitment to certain investigations that could benefit President Trump politically.

Mr. Giuliani also threw in a request of his own: help the mayor of Kyiv keep his job.

The mayor, Vitaliy Klitschko, a professional boxer turned politician and longtime friend and former client of Mr. Giuliani’s, was on the verge of being fired from his duties overseeing Kyiv’s $2 billion budget.

Firing Mr. Klitschko would have fit with President Volodymyr Zelensky’s campaign promise to fight Ukraine’s entrenched interests and allowed him to replace a political adversary with a loyalist in one of the country’s most important posts.

But despite the fact that Mr. Zelensky’s cabinet approved Mr. Klitschko’s removal, he remains there today, leaving his adversaries in the murky and lucrative world of Ukrainian municipal politics to wonder whether Mr. Trump’s personal attorney may have tipped the scales in his favor.