if u set the installation directory to the default value, the location of ur mysql data would be at /Applications/xampp/xamppfiles/var/mysql. u can try to copy and paste ur old databases to that location. take note that the procedure might or might not work, most of the time it might.
but really, the best option for u to move ur databases is by using the mysqldump function to dumping ur old databases into a sql file, then re-import the file back into ur new mysql.
refer to the manual if u're not sure how to use the mysqldump function
my 2 penny of opinion