modify JSON and override equals method for Key