I realise that you say that you can’t enable paging of users, but if it’s a case of you don’t know how, you can pass ‘number’ and ‘offset’ in the args array.
In your example to get page 2 of your users, set ‘number’ as ‘5’ and ‘offset’ as ‘5’.
If using those variables is not suitable you can always use a for loop with a count (instead of foreach) and insert a break every 5 iterations eg.
for ($i = 0; $i < count($students); $i++) {
// some code here
if ($i % 5 == 0 && $i != 0 && $i != count($students)) {
// insert page break code here
}
}