Beuran Hendricks claimed his maiden five-wicket haul as he dismissed Joe Root on day three of the final Test between South Africa and England.