I am also having similar problems with my ’04 rear hatch. Sometimes it works. Sometimes it won’t. Sometimes you can get it to work by pressing the on/off switch on the overhead console Off, then back on. This seems to “reset” it. Other times, this trick doesn’t work. Sometimes it works from the overhead button, but not the key fob. Other times, it may be the other way around. Sometimes the hatch will close on command, but it won’t pull fully latched. When this happens, it almost always becomes “disabled” until you manually open, then shut it, then toggle the on/off switch… These problems are very inconsistent, which makes things difficult to diagnose.
Surely someone here has some experience in troubleshooting this similar issue…