First, find out whether the goods are taxable in GST or not. Secondly check whether the goods were returned after 6 months from the appointed day. If the answer to both happens to be ‘yes’ then the person returning the goods will have to pay tax in GST.
However, where the goods are returned within 6 months from the appointed day, no tax will be payable by the person returning them if the goods are identifiable and tax was paid under the earlier law at the time of its sale, made not earlier than 6 months from the appointed day.
The relevant section is section 149.