generate unique instances based on ID by inheriting from this class