First, add a non-slip underlay, then use double-sided rug tape. And finally, choose rugs with non-slip rubber backing. Surely, these steps will help you.
Naturally, it's a pain to have to keep repositioning your rug, so the best way to stop rugs moving on the carpet is to use some anti-slip rug underlay for carpets. This is a tactile, non-slip, rubberized fabric that grips to the pile of the carpet underneath, holding the rug in place.