Donald Trump defeated Kamala Harris, becoming the second president in the nation's history to win nonconsecutive terms.