WASHINGTON—Even as President Donald Trump signed a bill August 2 imposing tough sanctions on Russia for interfering in the 2016 election, he called the law “seriously flawed” and said parts limiting his power to lift the penalties were unconstitutional.