Why might American Airlines fly a 767 from JFK to EWR?
It's a positioning ferry, to move the aircraft from where it "is" to where it "needs to be" for its next revenue leg (or maintenance, in some cases). These sorts of legs are uncommon because they're expensive; ideally an aircraft is never out of position this way, but sometimes "stuff happens" and you fly an empty plane to get it where it needs to be.