Personally, I think you should move custom validators out of your model and into its own validator class. You should read this guide, especially the part about custom validator: http://edgeguides.rubyonrails.org/active_record_validations.html#custom-validators
P.s. What you are doing is not wrong though, but it is usually better to extract complex behaviour with only one responsibility, in this case validating product attributes, into its own class. Custom validators are also great for keeping your code dry, because you can use them in any class you like.