Thanks for making this library available.
On the SAMD51 platform, the addresses to use are as follows:
#define SERIAL_NUMBER_WORD_0 *(volatile uint32_t*)(0x008061FC)
#define SERIAL_NUMBER_WORD_1 *(volatile uint32_t*)(0x00806010)
#define SERIAL_NUMBER_WORD_2 *(volatile uint32_t*)(0x00806014)
#define SERIAL_NUMBER_WORD_3 *(volatile uint32_t*)(0x00806018)
My board is a Feather M4; it can be detected by having ARDUINO_FEATHER_M4 defined, but there may be better/other ways of doing this (not sure if there is a SAMD21 vs SAMD51 definition).