U.S. House of Representatives Speaker Nancy Pelosi has said she will step down as the Democratic leader in the chamber.