You are a little confused. You can program the epcs using 3 different methods:
1 - Active Serial programming - This is not what you are trying to do so we'll skip it.
2 - JTAG Indirect Programming (JIC file) - If you are going to do this, then you use the Quartus convert programming file utility to directly create a JIC file from your SOF and any other data you need. You do not use the nios tools at all in this case.
3 - NIOS II flash programmer - This is my preferred method and it's also the fastest. you use the sof2flash and elf2flash utilities just as you have done to create ".flash" files for both your firmware and software images. Before you can program the EPCS you must program the FPGA with a SOF file containing your NIOS processor and an EPCS flash controller for this method to work. You can do this from the command line using the "quartus_pgm" command. Then At this point you just use the nios2-flash-programmer command to program the ".flash" files into the EPCS.