The idea is overcharging enough that you retain your profit margin rebating the deductible. Legality is state-by-state:
It is explicitly illegal in home repairs in Texas, do if you have roof repairs, you're out of luck:
Just be aware that most insurance agreements it will have language like "you will pay the deductible prior to any other part being paid" and so if you don't do this you could be accused of fraud without much of a defense. Will this likely happen, no, but regardless, I'd clear any repair ahead of time with your insurance company so you don't get stuck with the bill.