If your tendency is to sway, you restrict the power you will be able to generate in your golf swing. A sway indicates the excessive lateral motion with the lower body Swaying can be cause from an physical limitation including lack of mobility in the hips. You need to learn to rotate you hips level. This exercise will help you feel how your hips rotate in your backswing.
Use a chair or an exercise ball on a stand as your restrictor.
Set up as if you were going to hit a shot with your back leg next to the restrictor.
Make your backswing, keeping the weight on the inside of your back foot, so that your hip rotates internally, not laterally. Maintain the flex in your back knee. You should be able to turn to the top of your swing without touching the restrictor.
If you sway or your hips slide or move laterally as you swing to the top of your swing, you will bump into the restrictor.
Repeat the motion for 8 to 10 repetitions.
This is an isometric exercise that will train your muscles on the correct movement. Repetition is the key to correcting the motion.