Pay Back Health Insurance Coverage

I had health insurance covered by the government because my income was low enough I qualified for it. After 6 months I received a new job in a new state. I canceled the health insurance since I no longer qualified. When I went to do my taxes it says I need to pay back ALL the health insurance they provided for me since my annually income was more than I had qualified for. The only reason my annual income had increased was because of the new job and by then I canceled the insurance. Do I have to pay back for the insurance I had even though I qualified for it at the time? Or is there some other way to fix this?