Does anyone know how to create Geta.Categories programmatically?
Have you read this blog post? https://getadigital.com/blog/introducing-geta.epicategories---categories-as-localizable-icontent/
See also documentation on this page: https://github.com/Geta/EpiCategories
Geta Categories are just content. So you can interact with them just like pages and blocks using the IContentRepository. See here for more information on using IContentRepository to save content: https://world.episerver.com/documentation/developer-guides/CMS/Content/Persisting-IContent-instances/