Only one way to do that set the tank as the party leader. Be aware though doing such is more dangerous as the longer the bot is with them the more obvious to the other party members you are using a bot. Also, if the tank leaves the instance without requeing the bot will just sit there and do nothing until you remove the party leader from it.
EDIT:
Under normal circumstances the bot doesn't stay with any certain group because it becomes painfully obvious after 2-3 times that it moves exactly when the tank moves and other signs such as auto buff, auto misdirect and other things like that.