hasMany will generate "multi select box". In above example we have videos table with column article_id (that represent foreign key).
belongsToMany will also generate a "multi select box". In the above example we have a tags table linked to articles through a pivot table (article_tag). index is the primary key that allows us to fetch records in the tags table.
Here you need to setup validation rules (Laravel validation rules) for each table. It will be called when admin user want to create or edit some entity. Example: