I don't understand what you mean by 'using variables, it would work'. You can't divide by a variable which potentially takes the value of zero without branching your reasoning into "either <expression> = 0 or <everything from dividing by the expression onwards>".
this doesn't work with 0 values a good example is 2x=x (/x) 2=1 2x-x=0 x=0.In the above proof a^2-ab=0 because it is equal to aa-aa=0 and 2 times that will equal 1 times that.