If you want the information only, then you can use Structured Data Scraping which has an option to extract from multiple pages.
If you need to actually click on the links, then you will need to create some loop probably (instead of using Data scraping). The first thing I would check is if the selector for the link includes an attribute that has the Agent Name in it or anything that’s in the row to reference toward clicking the link. If it doesn’t, then you’ll need to go by the rowNumber attribute.
So essentially, you would use the Agent Name to find the rowNumber attribute (using Get Attribute activity), then in your Click Element selector use that variable in the rowNumber attribute.
You should have those 2 activities (Get Attribute and Click Element) inside a Try/Catch that is inside a Do While loop, so if the Get Attribute throws an error that means it needs to get to the next page, and you can place an page+1 and a Click in the Catch part, then it will loop and try to find the Agent Name again with the Get Attribute. Once it’s at the last page, another exception should be thrown which you can use to end the process.
I hope this is clear and helpful.