Beldum
(The one you thought was a robot)
Is a character made by eggsman that is meant to be god himself, I have hinted that the reason he's evil is because he was corrupted by some unknown entity, possibly even Mr void, but I'm not sure if it's canon yet.