You can set the ticket view option:
Go to the agent option, edit agent, and here show the permission option under the ticket view option to give individual access:

Now you can do this action from the admin side here you will be shown all tickets of the customers. Now you will assign to the ticket the particular agent you want to show the ticket to the agent.
Also, agent ticket view access should be individual access (this access provides only that ticket to the agent side when you will assign the ticket to this agent, not another customer ticket).