Crookshanks climbed up the drain pipe behind the old man's wand shop, made it to the roof, and jumped to the rooftop adjacent to it before finding a path to climb up in order to perch atop the roof of the next building over, continuing his daily sentinel duty of the building that makes all of the newspapers. Every afternoon, Rita Skeeter would go out for lunch and not return as soon as everyone else would. Crooks knew the witch could turn herself into a beetle (which amused him greatly back when she was stuck in the jar) and knew that must have been how she made it past enchantments and wards. That was how the rat Peter did it, and I never got the chance to kill him.