First create in MySQL server database with animals name. We do it in phpMyAdmin.
Click on Databases tab in phpMyAdmin.
In Create database field write animals, select utf8_unicode_ci as Collation and click on
You see animals database on the list.
Click on the name this database.
In empty Name field write classes and in Number of colmns field write 2.
Click on Go button.
In first Name field write id with PRIMARY for index and selected Autoincrement checkbox.
In second Name field write name with varchar type and 120 Length.
Click on Save button.
In this moment You have database animals contains one table classes. In the same way create animal table, but with columns: id as primary autoincrement key, name as varchar 120 length and id_classes as foreign key from id column of classes table. In id_classes row select in INDEX column INDEX.
Click on Structure link in animal table row.
You see list of columns this table, click on +Indexes, You see 2 indexes.
Click on Relation_view link.
Select in id_classes row in internal relation animals.classes.id and from foreign key
animals.classes.id, write constraint name as fk_animal_classes and select cascade for on
delete and for update. Save settings clicking on Save button.