Do you have a USB boot disk with macOS Mojave on it? If so, use it to completely erase the drive. Reformat it and then reinstall macOS.
Thank you for your answer. I do have it, but I don’t know how to completely erase both drives (SSD and HHD). Thank you.
https://www.imore.com/how-to-prepare-mac-for-sale
When you’re in the Disk Utility section, both drives should be selectable. Erase one and then do the other. Erasing instructions are included via the above link. I hope it helps you.