Yes, couples can be legally separated while living under the same roof.
It is possible to be legally separated while living in the same house. As long as the couple no longer acts as a unit (e.g., sleeping in separate bedrooms, not engaging in joint activities), they can be considered separated in the eyes of the law (Steps to Justice).