Sen. Tom Cotton told Politico that Cabinet members Rex Tillerson and Gen. Jim Mattis should resign if they can't execute on the president's directives that are in conflict with their own positions.

Cotton made the comments talking about the Iran nuclear accord, one that both Tillerson and Mattis have strongly advised the U.S. should stay in, but that President Donald Trump is reportedly going to decertify, Politico reported.

Cotton, R-Arkansas, sides with the president.

"They understand they're not the president," Cotton told Politico. "Donald Trump is the president. Their job is to advise. His job is to decide.

"When you think the president is wrong, you have a duty to try to present to him the best facts and the best thinking to help him see it in a different light. Maybe you can, but if he doesn't, and he says, 'No, I want to do it my way,' then your job is to move out and execute. And if you feel strongly enough, then you have to resign," Cotton told Politico.

Cotton's comments came last week in the aftermath of Secretary of State Tillerson's statement refuting a report that he had considered resigning out of frustration with Trump, but before this past weekend's war of words between the president and retiring Sen. Bob Corker, Politico reported.

Cotton also was addressing Defense Secretary Mattis' public assertions that staying in the Iran nuke deal was "in the national interest."

Cotton has been advising Trump about the new strategy in Iran, Politico reported.

Iran "is on the president's mind right now, probably more than anything," Cotton told Politico.