When on a list and performing a 'Group By' action on a column, the row count that appears in the pagination may not match with how many rows are appearing on the page.
There are two main reasons.
The first cause is that if you're grouping by on a column where there are empty values, these rows are grouped but not treated as a row count within the pagination.
The second cause is that if you're grouping by on a column which is a reference field, you can get what appears as duplications within the rows. This is because of the records in that table having the same display name value but are actually different values.
The recommendation would be to rename records so they do not share the same display name value so as not to cause confusion.