Should be no problem. That’s a good cooler and more than enough to keep an i5-8400 cool. Personally, I’d just get that cpu cooler. The intel coolers aren’t great. (Also can’t remember if the 8400 comes with a stock cooler)
If your not overclocking it depends on the CPU brand. Intel OEM coolers are generally crap for anything more than a Pentium or i3 while Ryzens coolers are good enough for general use and a little overclocking.
Should be no problem. That’s a good cooler and more than enough to keep an i5-8400 cool. Personally, I’d just get that cpu cooler. The intel coolers aren’t great. (Also can’t remember if the 8400 comes with a stock cooler)