Leading Tory Brexiteer Jacob Rees-Mogg told the Commons that he had confidence in the prime minister after she won the confidence vote.