How do I create database tables for a craft cms plugin on install? I am absolutely new to craft plugin development and could not find any documentation on creating database tables specific to a new plugin. How are new tables created when a plugin is installed?

I am browsing through the source code for the CocktailRecipes plugin: https://github.com/adrianmacneil/cocktailrecipes/ and I cannot find how the craft_cocktailrecipes_ingredients table gets created when I install it.

Is it merely a matter of defining a record class like CocktailRecipes_IngredientRecord and then overriding the getTableName and defineAttributes methods?

Is that how craft cms builds the tables?
PluginNameRecord.php is how Craft installs database tables. You can also have multiple tables by using PluginName_TableRecord.php where 'Table' will be the name of the new table in the database.

Might also be worthwhile to mention that the cocktails recipe you linked to has a lot of issues as it has not been updated for the latest versions of Craft. 

Sean Delaney updated that plugin and the new repository is here: 

https://github.com/seandelaney/cocktailrecipes