There is no legal rule for determining this: it's up to the co-tenants and the landlord to work this out among themselves. If the landlord is willing to rent only to you and B (and anyone else you bring in), but not roommate C, for example, then that's what will happen; on the other hand, the landlord could decide only to rent to C, but not you and B; or to rent to none of you; etc. It's a matter for negotiation.(Note: the above supposes that the current lease does not have some sort of automatic renewal term which affects the outcome; if there is such a term, you need to review your rights and obligations under it.)