The Roku's wireless connection is independent of the Samsung TV's wireless connection. I can't say connecting the device will be seamless as networks are quirky sometimes, but as long as you use a Roku that isn't old and lacking support, it should work.
You could try factory resetting your Samsung and see if it gets connected again. I would also try unplugging both the TV and router from power for 60 seconds and see if that helps, if you haven't tried that already. I have an older Samsung TV and they are finicky sometimes with the network, but usually one of those 2 things, especially the powering off, tends to help.
If your router is capable, you could also try setting up a separate guest network (Or IOT network) with 2.4 GHZ and/or WPA2 security and see if you can connect the TV or if possible, connect the TV via a network cable. Older devices sometimes do not like combo 5/2.4 GHZ networks and/or the latest security protocols WPA3/WPA2 combos.