My expertise is in marketing homes. Some buyers will value 5 bedrooms more than 4 bedrooms and some buyers would rather have 4 bedrooms and an office.
What is a legal bedroom? Who enforces and watches for "legal bedrooms"?
If you were marketing a home that had 5 really small bedrooms will that be worth more than 4 larger rooms? The answer is it depends on the buyer.
If your home had less than three bedrooms it would have a smaller marketing audience.
If your goal is to have the greatest marketing appeal then the answer is, "It depends on the buyer."
I would not jump through a bunch of extra hoops.