The interplay of self-interacting dark matter and baryons in shaping the halo evolution