When you install a WordPress plugin, it writes information into several tables (e.g., options table). Unfortunately, all those information is not deleted when you delete the plugin.
When installing the "Yoast" plugin, it adds four tables to the database and writes some information into other WP tables, too. When you deleted the "Yoast" table, did you delete "Yoast" related information from other tables? If not, reinstalling "Yoast" will give the error.
Fortunately, there is a solution to this error. Do the following to fix the error:
- Log into the WP as admin and go to the admin dashboard.
- Install the "Yoast Test Helper" plugin.
- Go to "Tools" and select "Yoast Test".
- Find the button "Reset indexables tables & migrations" and click it.
These steps should reset the needed tables and fix the error.