How merge categories?

You can bulk select all topics in a category and move them in another category.
Moving thousands of topics is not a simple job, before proceeding be sure to save a site backup.

Note that if you have migrated from another platform you could first check the site settings to make the site temporarily less restrictive and avoid errors. For example, you may want to allow duplicate topic titles.