Poor pay, growing workloads and the lure of more flexible jobs have left schools in England struggling to fill vacancies.