Greetings @leorpara
In order for room and board expenses to qualify the expense must be incurred when you (as the student) are enrolled at least half-time. According to the IRS,
"A student is enrolled “at least half-time” if he or she is enrolled for at least half the full-time academic workload for the course of study the student is pursuing, as determined under the standards of the school where the student is enrolled."
So if you're taking classes in May, and you're paying for your apartment, it would be considered a qualified expense. Section 529 does not care when the semester ends, only whether you are taking classes.
Good luck!
Brian Boswell VP, Research & Development
This information does not constitute tax advice and is provided for informational purposes only. Please consult your tax advisor, financial advisor, local taxing authority, and/or plan provider or sponsor for more information.