To make a direct replacement you'd need both old and new devices connected, which might not be an option with m.2 devices, you can still remove one device, convert pool to single, then add another device and reconvert to raid1, but before starting make sure your pool is redundant because of this bug, if you want post diags to confirm.