One way (which in my opinion is the better way, but we all know what opinions are like) is to treat is as a physically separate structure, since that's what it is. Actually makes things simpler if you sell or otherwise dispose of the property or any portion of it, in later years.
You'll declare that structure as 100% business use then. You'll have to manually allocate your expenses to that structure too. For example, you'll need to allocate a portion of your property taxes, insurance and mortgage interest to the structure, unless those items are actually billed separately. If the structure is on the same lot as your residence and you receive a single property tax bill for all of it, you'll also need to allocate a portion of your land cost to that rental also.
Once your percentage allocations are set up in that first year, they typically never change in following years unless you take some kind of action to change it.