Person 2: I put them on the table.
This sentence is correct. In response to a question in the simple past tense, it answers in the same tense. It states an action its subject has performed, but makes no formal suggestion about the current state of that action's object.
Person 1: Where did you hide my keys?
Person 2: I have put them on the table.
This sentence is incorrect in the given context because it is awkward to use the present perfect tense to answer a question in the simple past tense.
could I say, "where have you hidden my keys?"
This form is grammatically correct. Technically this differs in meaning from the question worded with the simple past tense in that the former asks about the present state of the direct object.
When a person asks the whereabouts of an object for which s/he is currently searching, the person is concerned with the object's present state, which would suggest that the present perfect must be used in such situations. However, in common speech, such questions are asked using simple past and present perfect interchangeably.
The tense used in the question will dictate the tense of the response.