Frollo does not care one bit for Quasimodo. He is only raising him because he fears for his soul if he doesn't. And if you remember the song in the opening scenes where Frollo sings "Even this foul creature may yet prove one day to be of use to me"
He is interested in Quasimodo only as a means to an end; his own soul not being damned, and potentially using Quasimodo at some point. He wants to use him as a pawn and so he manipulates Quasimodo to think that he is in fact his protector and wants what's best for him.
In reality Frollo only wants what's best for Frollo and when he teaches Quasimodo, he is simultaneously doing his very best to remind him how terrible he is; he's putting him down and bullying him, and making Quasimodo believe that that is what a loving parental figure should do. It's despicable.