Capital gains offset

Hello, can we Include upgrade and remodel costs in the purchase price of our new primary residence to offset the capital gains from the sale of our former primary residence on our 2021 tax return?