If they were—which no account of this case I’ve seen has suggested—there is certainly an ethical issue, but not an issue that should negate Motel 6’s liability under the state law at issue here. In fact, if it's employees were not aware of the prohibition on turning the material over without a warrant, and this were susceptible to social engineering indicating that they should do so, that would seem squarely to be Motel 6’s responsibility.
That’s why it’s strange here: ICE are agents of the federal government, who aren’t subject to state laws in the performance of their duty — Washington can’t stop ICE from doing their job, so instead they punish people who cooperate.
An analogy might be that mom and dad are fighting, and now punishing the kids who listen to the other parent.
ICE agents have some degree of lawful authority legally vested in them at some level of American governance, so it stands to reason that individuals can make the claim they felt 'required by some law' to do as that agency apparently behoved of them.
Especially if ICE were making statements along the lines of 'you're legally required to do this or that', then there's an issue here.