Don't do it. It's a small job, even for a relatively inexperienced homeowner, to install an additional direct feed from your dehumidifier into the main drainpipe.
For that matter, if you never use the dishwasher, disconnect its inputs and outputs completely, and use the connection from its drainline (into the main drainpipe) for your dehumidifier.
Some dishwashers will pump water even when not in a cycle (just poured a litre or so into mine to rinse it and it pumped automatically - the door was open so not a cycle. But it needs to be connected to the electrical supply.
However, I would not suggest that you do this - sort a proper drain for your dehumidifier. As you may end up with a stagnant smell ...
so some of the waste water from the dishwasher returns to the dishwasher when it finished pumping that's completely normal. There's no real way to prevent that.
So long as you don't get water from the sink or from the drain flowing into the dishwasher everything is fine.
This is exactly what an air gap is supposed to prevent. This is something that sits on the edge of the sink, and lies between the dishwasher and disposal, but I don't see one in your setup. This ensures that any backflow pressure won't go all the way back to the dishwasher. You can buy one at any home improvement store, but installing it might be annoying.
You don't need the compression nut. With that water hose, you should connect it directly to your water supply shutoff valve.
The compression nut is used when you have a copper pipe as your water supply, like this:
If that's what you have, remove the nut and the copper pipe. Your braided pipe connects to the water supply like this:
And connects to your ...