I had a similar problem with MAMP when I first started using it.
There was a file called config.inc.php that I had to edit. This question might help you, it's pretty much the exact thing I did to fix it.
This link will take you to the XAMPP equivalent answer to what I used for MAMP:
XAMPP MySQL password setting (Can not enter in PHPMYADMIN)
Specifically this part: (Couldn't get the code in the blockquote)
From "Xampp/phpmyadmin" directory in config.inc.php file find the
below code. And follow the given instructions below. I have tried like
this and I was successful to run both localhost/phpMyAdmin on browser,
MySQL Command prompt as well as MySQL query browser.
$cfg['Servers'][$i]['auth_type'] = 'config';
$cfg['Servers'][$i]['user'] = 'pma';
$cfg['Servers'][$i]['password'] = '';
$cfg['Servers'][$i]['controluser'] = 'user_name/root';
$cfg['Servers'][$i]['controlpass'] = 'passwaord';
And replace the above each statement with the below each corresponding
code.
$cfg['Servers'][$i]['auth_type'] = 'config';
$cfg['Servers'][$i]['user'] = 'root';
$cfg['Servers'][$i]['password'] = 'Muhammad Ashikuzzaman';
$cfg['Servers'][$i]['controluser'] = 'root';
$cfg['Servers'][$i]['controlpass'] = 'Muhammad Ashikuzzaman';
Basically, I had to change the file from the defaults to my username and password. After that I never had another login error.