During the summer, sure. Lots of students do. Consult the Summer Housing Site from Student Housing for eligibility, timing, price, and so forth.
But during the school year, it is generally not possible to live on campus unless you are an active student. There are two exceptions, both only for students who are very close to graduation.