The history of footwork in table tennis could take up a book by itself. If you watch videos of the best players in the world every 20 years or so, you can see the footwork techniques developing, though some of it is subtle and hard to pinpoint.
But one thing has been established at the world-class level since at least the 1960s - the best players almost all have wide stances. This gives greater stability and power to their shots while allowing great mobility. When moving, they often move both feet together. However, this is the result of years of training, especially physical training. Unless you are in good shape, using such a wide stance can be difficult. Find the right balance for you, which usually means as wide as you find comfortable.
Most footwork involves shuffling. Watch videos in slow motion of top players to see this, and how their feet move almost together. But for most of us, it's usually better to use what's called two-step footwork. Let's suppose you are a righty and want to move to your left.
Start with a neutral stance - left leg slightly forward, knees bent, weight on the inside balls of the feet, relaxed. Your first move should be a short step to the left with your left foot. Next, by first pulling with the left leg, you shuffle to your left, with both feet now moving together, almost a jumping motion except your feet almost brush across the floor. As you get better and better, the short step and the follow-up shuffle become closer and closer until they are almost one movement.
To move to the right, do the opposite - start with a short step with the right foot, then shuffle both feet together.
If stepping around the backhand corner to play a forehand, when shuffling both feet together (after the initial short step with the left), make sure your right foot swings far enough around (i.e. backwards, relative to you) so that you won't be cramped on your shot. Rotate your shoulders as your right foot goes around so that you end up with your shoulders at least parallel to the direction you are going to hit. Pull the playing arm back as you step around. Most of your weight should now be on your right foot. You are now in perfect position to attack with your foreland. Step into the shot with your left foot while rotating your shoulders, and either loop or smash. Make sure to finish the shot balanced so you can quickly move back in position for the next shot. If you don't follow through back into position, you will be out of position for the next shot.