Justin Gaethje beat Ilia Topuria to win the lightweight championship in the main event.