Target Display Mode is not an option. You can use Screen Sharing (e.g. Virtual Network Computing or VNC) between your Mac mini and the iMac. Your iMac keyboard and mouse will drive the mini screen, and you have drag/drop file transfer via that window.
On the iMac, drag and drop /System/Library/CoreServices/Applications/Screen Sharing.app to your Dock. On your Mac mini, in System Preferences : Sharing : [√ ] Screen Sharing. You may have to visit the Security & Privacy panel : Firewall : Firewall Options: and disable Block all incoming connections, and select Automatically allow built-in software to receive incoming connections. You should see Screen Sharing in the panel above with a green indicator. Don't forget to reselect Block all incoming connections when you are in an unsecure Wi-Fi (e.g. public) environment to block access to VNC.
Back on the iMac, click the Screen Sharing icon in your Dock and enter the hostname of the Mac mini as hostname.local, where hostname is the name you gave your Mac mini. Only due this after your Mac mini has been powered on long enough to boot, or the Screen Sharing application will give up on you.