A man has died after being hit by an ambulance that was taking a patient to hospital near Sunderland, police said.