Using frozen dataclasses for immutable objects