Having done a huge amount of ground work with my mustangs and trained both of them to longe properly, hopefully I can help.
-- I would advise using a rope halter because it will give you a little more power without potentially getting twisted, bunched up, or improperly positioned as a chain frequently can.
-- You haven't mentioned, but I hope you are just starting off with a standard length lead rope (10-12') and not a long longe line. To start off, you want to keep them on a fairly small circle.
-- Gloves! When doing groundwork with a green horse who may overreact, it is important to have gloves which will allow you to hold on tight when neccessary without fear of getting rope burn.
-- A whip or crop (my favorite to start off is a dressage whip) is also helpful for clarity of signals. Your stick with the flag will work too but if these things freak him out, first you ought to desensitize him to it and show him it won't hurt him. This video shows what your horse should be allowing you to do before you use the whip for a lot of work:
Things to understand:
-- My sense is that you are doing too much all at once. To start you won't be "longeing" so much as asking him to walk calmly around in a circle and yield his shoulders to change direction.
-- Part of his being squirrelly to the right may be that he's just not used to having a person working with him from that side. Most people lead from the left, but you should make sure that he is also okay with being led from the right.
Here is a video showing the sorts of things you'll want to be doing before you are "formally" longeing:
Here are some things to note about the video:
-- The handler is looowww energy and chill. She only increases energy when it is necessary to encourage the horse to keep moving or to change direction. Even if your horse is throwing a fit on the end of the line, it is important to keep a firm hold and remain very calm until he figures out that there's really nothing to be creating such a fuss about.
-- Note that as soon as the horse does as she asks (changing direction or speeding up) she becomes passive and allows him to continue on his own.
-- When she changes direction, she swaps which hand is holding the lead rope, backs up to tip the horse's nose towards her, then motions with her opposite hand to encourage him to yield that shoulder and change directions.
-- She introduces a little trot and some backing up later in the video, but I wouldn't start any of this until you have him calmly walking both directions and changing direction.
Once you have him quietly walking and changing direction, you can introduce a bit of trot on the small circle (as in the video). Once all of that is going well, you can start using a longer line and encourage him to move farther out on a larger circle. When he is transitioning between walk/trot and changing direction nicely on the larger circle, you can start to ask for a little canter.
Hopefully that sort of helps.