They both run S2, so they can be grouped. You’d need a second PLAY:3 if you planned on using the pair as surround speakers, though. Given that the PLAY:3 hasn’t been manufactured for many years might make that challenging.
Note that if grouped, the PLAY:3 will play the TV input to the Sonos Ray slightly delayed, but when streaming music, they’ll be in sync.