Rouhani made the remarks in a phone call with his Indonesian counterpart Joko Widodo on Monday.
“[Such] illegal instances of opposition can prove dangerous in circumstances when all of the countries of the world are engaged in fighting the coronavirus,” the Iranian president added.
The US returned the sanctions in May 2018 after unilaterally withdrawing from a nuclear agreement among Iran and other countries that has been endorsed by the United Nations Security Council.
Iran sued the US at the International Court of Justice afterwards. The tribunal ruled that the US should lift its sanctions on humanitarian supplies.
Washington alleges that it has exempted foodstuffs and medicine from the bans. Tehran roundly rejects the claim.
Washington has also refused to lift its sanctions amid the viral pandemic which has complicated Iran's battle against the outbreak.