You probably typed it wrong.
Make sure to enter the code exactly the same as your given code in the box. Case and all.
Also, watch out for 0 and O and I and 1.
However, if it is indeed invalid, you'll probably need to take it up with the retailer that sold it to you.