Check out example codes for "add auto_increment column to existing table mysql". It will help you in understanding the concepts better.

Code Example 1

ALTER TABLE `users` ADD `id` INT NOT NULL AUTO_INCREMENT PRIMARY KEY

ALTER TABLE `users` ADD `id` INT NOT NULL AUTO_INCREMENT UNIQUE FIRST

Learn ReactJs, React Native from akashmittal.com