The pin-files are in Marlin/src/pins/lpc1768 directory, at least on Marlin 2.0.0. For Bigtreetech SKR 1.3 the files to modify seem to be pins_BTT_SKR.h and pins_BTT_SKR_V1.3.h. I'm not completely sure how this should be done, but I'd try renaming all definitions starting with E1_ to Z2_ and see if that fixes things.