On generalized Kerr–Schild transformations