Check out example codes for "how to rename a table in ruby". It will help you in understanding the concepts better.

Code Example 1

class RenameOldTableToNewTable < ActiveRecord::Migration
   def change
     rename_table :old_table_name, :new_table_name
   end 
 end

Learn ReactJs, React Native from akashmittal.com