If your battery is replaceable, you can still decide to throw the phone away and add to the pile of e-waste.
The legislation allows both choices, at the cost of higher prices.
Having a higher price is an incentive to using the phone you have a bit longer by replacing the battery. It’s certainly better than having them be guaranteed e-waste.