A 52-year-old teacher has been sentenced to life imprisonment for raping and impregnating a student after eloping with her.