The loan servicer will end your deferment when your school says you're no longer enrolled. Then the loan servicer will send you a notice that you have to start paying again. Sometimes this is 6 months after your enrollment ends, but not always. Basically, everybody needs to talk to everybody, and then stuff happens as you'd expect.
When you're back in school, your loan servicer will give you a deferment after they find out that you're enrolled. Some schools automatically notify the loan servicer (oh, so convenient). Or you might need to provide proof of enrollment. Your financial aid office at your school, and/or the registrar have the forms, undoubtedly.
Plan on needing to make a few payments after you're enrolled, while the paperwork goes through.