The BBC's director-general Tim Davie and Deborah Turness, the CEO of BBC News, have resigned from their positions.