Frappe change page routing according to role profile

I am creating a LMS in frappe with four Role Profile (Admin, Parent, Mentor, Student) when i add user or invite user in the role profile of Student for the first time(user who sign up first time) should not directly redirected to courses before redirecting to courses i need take survey of student and categorize them help me to do that

for now invite a user as Student
it give a link to set password after successfully setting the password it redirects to course

but when i invite a new user as Student i need to take survey from students before redirecting to courses