This is a surprisingly complicate issue, and I don't think tht there is one right way to do it. My short answer is:
Yes, you can move between an attack and an attack granted by Flurry of Blows.
It also does not matter whether you attack at melee or at range and you can also move between the attacks granted by Flurry of Blows.
For my reasoning, an explanation follows. It is rather lengthy since there are quite a few things that come into play here.
The rules on moving between attacks state (PHB, p. 190):
If you take an action that includes more than one weapon attack, you can break up your movement even further by moving between those attacks.
Flurry of Blows clearly qualifies for this since it is an action that includes two weapon attacks. So you can move between the two attacks granted by the Flurry of Blows. This interpretation is also supported by the series of tweets from August 2014 by Mike Mearls that Miniman's answer also links to.
On the other aspects, Flurry of Blows is quite nebulous. The feature is defined as follows (PHB, p. 78):
Immediately after you take the Attack action on your turn, you can spend 1 ki point to make two unarmed strikes as a bonus action.
There is one major issue to be resolved here: when have you actually taken the Attack action? As I see it, there are three possibilities:
- After you have made the first attack.
- After you have made all the attacks (should you have any Extra
- Before you make the first attack.
The first option is based on reasoning that the first attack is the actual Attack action, and any possible Extra Attacks are just that: extra.
The second option is based on reasoning that the Attack action is not really over until you have taken all the attacks it grants you.
And the third one is based on reasoning, that the Attack action does not really mean that you have to actually make an attack in order to qualify for taking the action, rather the Attack action just grants you a "pool" of attacks that you can draw from. This definition is important since the Flurry of Blows says that it has to be taken "Immediately after you take the Attack action".
The important parts defining the Attack action are as follows (PHB, p. 192; flavour text and simple examples omitted):
With this action, you make one melee or ranged attack. Certain features allow you to make more than one attack with this action.
This doesn't really give us much to work with, so I'll rely on reasoning based on what follows from every interpretation.
Following the first interpretation, you would have to decide to use the Flurry of Blows after you have resolved your first attack, so you have only the result of that first attack to figure out if you feel like you want to use Flurry of Blows. Additionally, you would then have to make (at least) the first unarmed attack granted by Flurry of Blows before you can make any further attacks granted by the attack action, since it grants attacks and would therefore have to be treated the same way as the Attack action, meaning you haven't taken it until you have made at least one attack. To me, this feels overly restrictive and unintuitive and as such I would not personally follow this interpretation.
Following the second interpretation that your Attack action is over only after you have made all the attacks granted by it, you get the most information out of your attacks before having to decide if you want to use Flurry of Blows. The drawback is that you cannot make any Flurry of Blows attacks before you have made all the attacks granted by the Attack action. Alternatively, you could choose to forgo your remaining regular attacks and declare the action is over (this has to be possible or you will run into some serious trouble, e.g. people having to attack targets they don't want to) to use Flurry of Blows, but then you would lose those regular attacks. This interpretation also seems restrictive and weird, so I would not follow this one either.
This leaves us with the third option that the Attack action is not actually tied to any actual attack, but rather is the source of a pool of attacks. This option is the most restrictive on when you have to decide to use Flurry of Blows (i.e. before you have even attacked a single time) but the least restrictive on when you can make those additional unarmed attacks, since it would then also just grant you an additional "pool" of two unarmed attacks to use when you want in addition to whatever attacks you gain from the Attack action. This may not be the most elegant way to handle it either, but definitely the best one that I can argue for based on rules-as-written. It would also seem to fit the general design philosophy of a turn of combat, where you can quite freely mix and separate different actions.
This leads to the conclusion that you have to use the Flurry of Blows feature, spending the bonus action and one Ki point, immediately after you declare that you will be attacking this turn, but before the first attack is resolved. You are then able to use your regular attacks and Flurry of Blows attacks in any combination and moving between any of them if you want.