Sen. Bernie SandersBernie SandersSanders keeping door open on 2020 Parliamentarian deals setback to GOP repeal bill OPINION | Hey Dems, Russia won't define 2018, so why not fix your party's problems instead? MORE (I-Vt.) hit President Trump on Tuesday, questioning whether the commander in chief knows "what being president of the U.S. is about."

"I think, for whatever reason, Donald TrumpDonald TrumpScarborough, Brzezinski named rabbit after Trump Trump Jr. adds to legal team ahead of Senate meeting Conway: Trump doesn't think he's lying on voter fraud, wiretap claims MORE doesn't fully understand what being president of the U.S. is about," Sanders said. "When you sit in a room and, by the way, exclude American media and only have Russian people coming in, and then you tell Russians highly classified information that is endangering our security as a people. ... This is a big deal."

Sanders was referring to a report on Monday that Trump shared highly classified information with Russian officials while they were visiting the White House last week. Sanders criticized the president for sharing the information, saying it could damage our relationships with other countries and put people in danger.

"This president better learn what it's like to be president and not share classified information with people who do not wish us well," Sanders added.

Current and former U.S. officials told The Washington Post Monday that Trump relayed information from a critical source of intelligence on the Islamic State in Iraq and Syria.

The information was provided by a U.S. partner through an intelligence-sharing arrangement. The partner did not give the United States permission to share the information with Russia.

Sanders has been an outspoken critic of Trump but has offered to work with him on legislation multiple times.