Interesting, is that in the US? I’ve never heard of that being required by law in the UK. I think it’s just an Apple thing here. I mean we obviously have laws about refunds etc but I don’t think we have any law saying you can open any product and start using it and then return it even if you have no complaint with it.
There is no uniform law. In the EU most countries have this type of laws but they all vary in the duration and scope. In the US is more or less similar as it varies by state and many don't have any laws regarding this.
But even the more permissive laws have many exceptions, like not applying to perishable goods, underwear, lipstick, etc. and it's heavily tilted for unused products or very light us that doesn't affect the value of the product when re-sold.
When the product doesn't work like in the case of this Apple situation, it's not even a question. As long as the hardware is not damaged and everything is return, "the law" completely sides with the consumer.