Coriolis where she brings up that same point, but edited it out to try to be a bit more concise.
Satan as devil's advocate in the story of Job is still pretty consistent with the idea that the Devil is a pre-Freudian representation of the ego. Honestly, all of the OT is just a series of allegories about the confrontation between the individual will and the divine will. And if you think about it a little more you recognize that God had to have had a hand in instigating every single one from Eve onwards (who created the Apple afterall?), it's just laid out a little more explicitly in Job than it is elsewhere.
But it gets at this deeper point that even the ego, the part that actively wars with our Creator, was created by him too, which is why the Lucifier myth is so poignant. So a much more significant question than what is the Devil is why there's one at all. Satan makes sense only from a psychological perspective that, as it was so astutely pointed out to me by @Ginkgo recently, our inability to fully integrate the shadow causes us to project autonomy onto it. Satan is the emblem of the collective strain of choice--free will's dank underbelly.