Simply cut the "continuing" wire where it went over the screw of the switch that's being replaced, then strip the ends and pigtail
Some electricians will strip the insulation from the middle of a length of wire and loop it around a terminal-screw to continue it onto other terminal-screws, as you see in your box here. While this works fine as long as terminal-screw devices are installed, it doesn't work so well with dimmers, smart-switches, and such that bring their own wire pigtails, such as yours.
So, you'll need to convert this to a more traditional wirenut-and-pigtail setup. With the breaker off, you'll need to take the always-hot (continuing) and ground wires off the old switch, cut them at where they were connected to the old switch, strip both cuts ends back a bit more, and nut them to the corresponding pigtails on the new switch. From there, you can remove the black switched-hot from the old switch and nut it to the switched-hot pigtail on the new switch, and finally connect the neutral from the new switch in with the bundle of neutrals already present in the box now that the old switch is completely unwired. Once everything's buttoned up and ready to go, you can flip the breaker back on and enjoy your new occupancy sensor!