U.S. President Donald Trump's embattled national security adviser Michael Flynn resigned late Monday night, following reports that he had misled Vice-President Mike Pence and other officials about his contacts with Russia. His departure upends Trump's senior team after less than one month in office.

In a resignation letter, Flynn said he held numerous calls with the Russian ambassador to the U.S. during the transition and gave "incomplete information" about those discussions to Vice-President Mike Pence. The vice-president, apparently relying on information from Flynn, initially said the national security adviser had not discussed sanctions with the Russian envoy, though Flynn later conceded the issue may have come up.

"I may have been careless in some of my discussions and I accept full responsibility," Flynn said in statement.

Trump named retired Lt.-Gen. Keith Kellogg as the acting national security adviser. Kellogg had previously been appointed the National Security Council chief of staff and advised Trump on national security issues during the campaign.

Warned weeks ago

The Justice Department warned the Trump administration weeks ago that contradictions between the public depictions and the actual details of the calls could leave Flynn in a compromised position, an administration official and two other people with knowledge of the situation told The Associated Press Monday night.

One person with knowledge of the situation said the Justice Department alerted the White House that there was a discrepancy between what officials were saying publicly about the contacts and the facts of what had occurred.

A second official said the Justice Department was concerned Flynn could be in a compromised position as a result.

The White House has been aware of the Justice Department warnings for "weeks," an administration official said, though it was unclear whether Trump and Pence had been alerted.

The people insisted on anonymity because they were not authorized to discuss the matter publicly. The Washington Post was the first to report the communication between the Justice Department, including former acting attorney general Sally Yates, and the Trump administration. Yates, in her last days on the job, was publicly let go after disagreeing with Trump's controversial immigration executive order.

Flynn apologized to Pence last week, following a Washington Post report asserting that the national security adviser has indeed discussed sanctions with the Russian envoy.

Retired Lt.-Gen. Keith Kellogg seen at Donald Trump's Trump Tower in New York on Nov. 15, 2016, will be acting national security adviser in the wake of Flynn's resignation. (Carlo Allegri/Reuters)

Conspicuously silent

White House spokesman Sean Spicer said Trump was consulting with Pence on Monday about his conversations with Flynn. Asked whether the president had been aware that Flynn might discuss sanctions with the Russian envoy, Spicer said, "No, absolutely not."

Trump, who comments on a steady stream of issues on his Twitter feed, has been conspicuously silent about the matter since The Washington Post reported last week that Flynn had discussed sanctions with the Russian envoy. A U.S. official told The Associated Press that Flynn was in frequent contact with Ambassador Sergey Kislyak on the day the Obama administration slapped sanctions on Russia for election-related hacking, as well as at other times during the transition.

Flynn sat in the front row of Trump's news conference with Prime Minister Justin Trudeau earlier Monday. The president did not receive a question about Flynn's future from the two reporters who were called upon, and he ignored journalists' shouted follow-up inquiries as he left the room.

Flynn's discussions with Kislyak raised questions about whether Flynn offered assurances about the incoming administration's new approach. Such conversations would breach diplomatic protocol and possibly violate the Logan Act, a law aimed at keeping private citizens from conducting diplomacy. The conversations also raise questions about Trump's friendly posture toward Russia after U.S. intelligence agencies concluded that Moscow hacked Democratic emails during the election.

Russian President Vladimir Putin, centre right, sits with Michael Flynn, centre left, and others at an exhibition marking the 10th anniversary of RT (Russia Today), the 24-hour English-language TV news channel, in Moscow, in December 2015. (Mikhail Klimentyev/Sputnik, Kremlin Pool Photo via AP)

Anti-Russian feeling

The Kremlin early Tuesday referred to Flynn's resignation an internal matter for the United States

"We've said everything we want to say," spokesman Dmitry Peskov told reporters on a conference call.

Peskov previously said that Flynn and the ambassador did not discuss lifting sanctions in their conversations. He declined to elaborate on those earlier comments when asked on Tuesday.

A senior Russian lawmaker said the resignation of Flynn suggested Trump had been backed into a corner or that his administration had been "infected" by anti-Russian feeling.

"Either Trump has not gained the requisite independence and he is consequently being not unsuccessfully backed into a corner, or Russophobia has already infected the new administration also from top to bottom," MP Konstantin Kosachev was cited as saying by the RIA Novosti news agency.