Assistant professor from Ms in cse background can teach mtech cse students
For Postgraduate the professors must have a phD. So with only MS one is not eligible to take classes of MTECH.
I hope my answer helps. All the very best for your future endeavors!