Hi Clare,
Thanks for your question.
Unfortunately, you would have to complete two separate Tax Returns covering the periods 6th April 2023 to 5th April 2024, then a partial year Return up to the closing of your rental business in August.
Also, you would not be able to offset such losses against a previous year, only against a future year or against general income for that year, as per PIM4205 attached:
PIM4205 - Losses: overview.
Thank you.