Use the $currentUser variable, this always includes the data of the currently logged in user.
The above statement retrieves a user with the same role as the current user and is also active. If there is no sorting this will give you a random object with these conditions. In a microflow you should just use the $CurrentUser/name if you want to have the account name of the user.
Hey Venkat, What are you trying to accomplish and where in Mendix: page or microflow?
I guess you want to retrieve the users with the same userrole as the logged in user on a page. The XPath you have is correct, but the Mendix security, with level Production, is the one what is interfering. In the Mendix security the userrole must be able to manage it self to retrieve other accounts with the same userrole. If not, it only retrieves itself.
I hope this helps, otherwise can you please give some more info.