Cool circumgalactic gas in galaxy clusters: connecting the DESI legacy imaging survey and SDSS DR16 MgII absorbers