Windows has a lovely “feature” where it installs the bootloader on a secondary drive if there’s one connected. It doesn’t install it on drive 1 and drive 2, just drive 2. I always disconnect all secondary drives before installing windows for this very reason.
That said you can configure the windows bootloader to recognize your Linux (or grub) and just use that to manage booting two OSes and it’s less likely to not destroy things.
It's relatively quick and easy to fix if you have a live boot Linux usb stick ...and probably a second machine so you can Google what to do. It's just also rather worrying at the time.
My old thinkpads have this great feature where the hard drive is easilly accessible on the side, so I leave the cover off and just swap the drive to boot into a different os
iirc the last time it happened to me, i just needed to fix the uefi entry which wasnt that bad.
(just remember to have a usb stick with a live image ready)
if it were to overwrite your bootloader that would be a way harder fix.