Three-quarters have considered leaving the profession in the past year, with most blaming staffing shortages and safety concerns, the Royal College of Midwives said.