Your question is not one so much of legality or illegality but rather one of being respectful and honoring boundaries. Since you are a tenant in the unit you share with your sister and your boyfriend, he has no right to simply enter your bedroom without your permission whether you are home or not at home.