Your assumption is correct. There is no reason why being a Ranger's Animal Companion would cause a mount to forget or ignore its training. The quote you've included contains the key piece of information here:
You can control a mount only if it has been trained to accept a rider.
So Dash, Disengage, and Dodge are things it has been trained to do when a rider on its back gives the appropriate signals. (Digging in their heels, shaking the reins, however it works.) It doesn't cost any actions from the rider because the mount has been trained to respond to the rider in these ways.
And as you've said, it would still cost one action while not mounted; at that point, you're back to your ability to verbally command it using your action.
Only if it can be used while still being the fastest option
Flee. The target spends its turn moving away from you by the fastest available means.
Usually, the fastest available means will be via the dash action. But this may differ depending on type of creature and/or class.
If the fastest way for that particular creature indeed includes using the disengage action (see goblin example below), then they are able to do so.
In the much more likely case of another method being the faster option, they must do that instead.
Examples
A goblin has an ability that allows them to disengage (only) as a bonus action so they would be able to both disengage and dash, for example. In this case, there is no way the goblin can go faster so using the disengage (bonus) action would be wholly within the rules. (thanks @András)
A rogue can disengage as a bonus action as well but, since they can also use that bonus action to dash, dashing twice (action+bonus action) would be the fastest option. So a rogue would not be able to use disengage.
Sidenote: OA aren't relevant in determining flee path
Command also says:
The spell has no effect if [...] your command is directly harmful to
it.
Jeremy Crawford has ruled that:
Command: Flee isn't directly harmful; OA may or may not happen. "Jump
in the lava" & "Stab yourself"—harmful.
So, OA should not be a consideration for the creature in adhering to the effects of the spell.
Best Answer
If the Dash action is the fastest means of fleeing available to them, then yes, they will use it. For a counterexample, a monster with the ability to teleport (like a yugoloth) would probably do that instead.
If the Disengage action is the fastest means of fleeing available to them, then yes, they will use it. (I really can't think of a way to make this true, though.)
A creature under the effect of a Command to flee uses its own movement, so yes, it will provoke opportunity attacks.