If a spell such as Find Familiar or Animate Dead, or a feature such as the Beast Master’s Ranger’s Companion or the mounted combat rules allows a player to control another creature in combat, that spell or feature specifies the limits of that control. For example, Familiars, as per the Find Familiar spell, act on their own Initiative, are controlled by the player in combat, abd cannot Attack (with the exception of Pact of the Chain warlocks, which can command their familiars to attack on their turn as an action.) I simply follow these rules as written. If an ability does not specify that a player can control a creature’s action - for example, in the case of an intelligent mount - then I control it.
The Beast Master’s Ranger’s Companion is an interesting edge case, because originally it was not specified what the beast did with its action if the player didn’t spend an action to command it. Personally, I filed that under the category of unspecified control, which meant it defaulted to me to choose how it acted, and generally I would have the beast’s first priority be to defend its master, and second priority be to defend itself. But then it was errata’d to take the Dodge action if not commanded otherwise, which I personally think is kinda dumb, so I ignore it and run it the same way I did prior to the errata.
Out of combat, players control their own characters and I control all other creatures. With familiars, mounts, animal companions, and minions, I generally allow the player a great deal of input on how they behave, but I ultimately narrate what they do.