uBlock was maintained by one person, but they wanted to move on to other projects, so they handed the project to someone else. The other person horribly mismanaged the project, and contributed essentially nothing. The original developer decided to return with uBlock origin.
Forks happen. Things don't always go as planned. The original author of uBlock handed over the project to someone else, who promptly contributed nothing to the project other than to slap a "Donate" button on the page. The original author then reasserted control over the project by making uBlock Origin.
So to recap, uBlock is a stagnant branch of the project that has not been updated in some time and has seemingly been abandoned by the maintainer to instead work on a paid adblocker for iOS. uBlock Origin is actively being developed, and helmed by the original author. Use uBlock Origin. In a perfect world you wouldn't need to, but, it is what it is.
It might be helpful to think of them both as open source projects (though it's slightly murkier) where there have been forks and drama in both codebases.