U.S. President Donald Trump said following his first White House meeting with NATO's secretary general on Wednesday that the security organization "is no longer obsolete."

>> Get all updates on U.S., Russia and the Middle East: Download our free App, and Subscribe >>

During his election campaign last year, Trump attacked NATO a number of times, even doubting its necessity, but gave a firm commitment to the alliance in his first speech before Congress in February.

Standing alongside NATO Secretary General Jens Stoltenberg, Trump said that he will work to enhance the partnership with the organization.

<< Analysis: Trump's Comprehensive Demolition of Putin's Gas-attack Cover-up Propaganda >>

Speaking of Russia, Trump said that "we'll see about" Washington's relationship with Russian President Vladimir Putin following last week's gas attack in Syria.

"Right now we're not getting along with Russia at all," he said. Referring to Russian involvement in the gas attack in Syria, Trump said that "I think it's possible, but probably unlikely. I'd like to think they didn’t know."

Trump said that the was grateful for NATO members' support in condemning the gas attack in Syria, adding that it was time to end Syria's civil war, defeat terrorists and allow refugees to return home.

Syrian President Bashar Assad, Trump said, is a "butcher."

>> Read more: Iran's Exiled Prince Wants a Revolution - Even With the Help of Israel or Trump

Stoltenberg said he and Trump agreed that NATO must do more in the global fight against terrorism and that the issue will be at the center of the upcoming NATO summit.

A senior White House official said that among the issues the two leaders were to discuss is Russia’s attempts to thwart the expansion of NATO, specifically by intervening in the elections that took place last year in Montenegro, a Balkan nation on the verge of joining the trans-Atlantic military treaty.

The Senate voted overwhelmingly to approve Montenegro’s entrance into NATO, and according to the senior official who spoke ahead of the Trump-Stoltenberg meeting, the president also supports the move and sees it as necessary to counter Russian ambitions in Europe.

>> Explained: Why Is Russia Meddling in the Middle East Anyway? >>

Trump approved the Senate vote on Montenegro 24 hours before the meeting with the Secretary General of NATO, and declared that Montenegro’s admission into the alliance sends a strong message that “countries in the Western Balkans are free to choose their own future and select their own partners without outside interference or intimidation.”

Trump's statements against NATO during the campaign were seen as part of his attempts to shift U.S. policy toward Russia and move the country away from its current role as “the world’s policeman.” Trump continued to speak against NATO after his victory, at one point even declaring in an interview that the decades-old military treaty was “obsolete.”

And yet, in his first test on the subject as president, he chose to go along with the traditional U.S. policy by supporting Montenegro’s bid to join the alliance. In the briefing on Wednesday, the senior White House official blamed Russia for interfering in Montenegro's democratic process in an attempt to stop its accession into NATO, and at some point of even plotting a violent election-day coup in the small Balkan country.

The senior official added that Trump and Stoltenberg will also discuss the situation in Syria and Russia’s interference in Ukraine, and that the president will publicly present a strong commitment to NATO as he did to both houses of Congress in late February. However, the Trump administration will continue to demand that all NATO countries increase their military spending – something that the alliance’s members had already agreed on in 2014. Trump wants to see a detailed plan on how each country will deliver on that promise.

Reuters contributed to this report.