The <li> element is the parent for each person that you might want to click on. If you get the index of the one you want to click on via using Extract data from web page (to extract all names) and then Find or replace in data table (to find the name you are looking for in the table you extracted), you can pass that as a variable to your selector.
Do li:eq(%index%) to set an ordinal value using a variable called %index%.
Of course, you need to click on one of the child elements of the <li> element. So, you need to capture the actual element you want to click and then modify its selector so that the <li> part depends on which item you want to click on.
See here for reference on how to add variables to selectors: https://learn.microsoft.com/en-us/power-automate/desktop-flows/build-custom-selectors#use-variables-...
Also watch this video on building dynamic web selectors: https://youtu.be/2PcyBa22Jj8
-------------------------------------------------------------------------
If I have answered your question, please mark it as the preferred solution.
If you like my response, please give it a Thumbs Up.
If you are interested in Power Automate, you might want to follow me on LinkedIn at https://www.linkedin.com/in/agnius-bartninkas/