1. Let's take a rest.

2. Let's take some rest.
3. You should get some rest.
4. You should get a rest.
5. You should rest for a while.

Are they all grammatical? Which ones are frequently used?

They are all OK, but some are more frequently used than others. One usually speaks of "having", rather than "taking" a rest. One "takes" a break but "has" a rest.

I am not clear why "a rest" fits better in some situations and "some rest" in others. #4. would be better as "You should get some rest" (sometimes) or "You should have a rest" (now)

The best two grammatically and idiomatially speaking are 3 and 5. The others could mark the speaker as non-native.