To return a warranty (if it's a seperate item) you take it back with the reciept. Usually within the 2 weeks after purchase, details are usually written on the back of the reciept.
You have 30 days to return your item. Most other things like phones are returnable in 14 days. There is a restocking fee if the item has been opened, but I believe that applies to everything returned.
Thanks! Your answer is awaiting moderation.