I'm sorry for your loss.
If Filevault was enabled, then you can only reset the password using the information in this Apple article:
https://support.apple.com/en-us/HT202860
https://support.apple.com/guide/mac-help/reset-your-mac-login-password-mh35902/mac
If Filevault is enabled, then the system has the data encrypted. Without a Filevault Recovery Key or the password, you cannot access the data on the encrypted drive.
If Filevault was NOT enabled, then you should be able to connect the removed drive to another Mac to access the contents of the drive. If either drive has more than one macOS user account on it (or ever had more than one account at some point), then your father's files/folders inside his home user folder will be locked due to permissions issues. You can either try copying the whole folder (Desktop, Documents, or any other) which should have macOS prompt you for your admin password. In theory, the items should copy and now be associated with the permissions for your macOS user account (it worked for me a few years ago anyway).
If Filevault was NOT enabled, then you can also try creating a new macOS admin user account using the instructions in this article as a guide:
Restarting Setup Assistant to create Admin user - Apple Community
The only difference in the procedure for older versions of macOS is the location of the mounted volume which would be "/Volumes/Macintosh HD/private/var/db/.AppleSetupDone" if booted into Recovery Mode. For older versions of macOS like 10.13, It is much easier to boot into Single User Mode with Command + S. Follow the on screen instructions to run "fsck" and "mount", then use the "rm" command in the article with the path being just the simple "/private/var/db/.AppleSetupDone". For Single User Mode (Command + S):
fsck -fy
mount -uw /
rm -i /private/var/db/.AppleSetupDone
Another option is to use Carbon Copy Cloner (CCC) to transfer the items since CCC will ask for admin privileges in order to access all areas of the source location. CCC also allows you to toggle which items you want to transfer. CCC has a free trial period.
If your father's iMac was running macOS 10.13, then it may be using the APFS file system which will require having at least macOS 10.12.6+ on the host Mac since older versions of macOS won't be able to read an APFS volume or container.
If your father's iMac had a Fusion Drive (an internal SSD & internal hard drive), then leave both drives installed internally in the iMac and utilize Target Disk Mode to access those files.