Updating routing table
If you create a new subnet in this VPC, it's automatically associated with the main route table, which routes its traffic to the virtual private gateway.
You can explicitly associate a subnet with the main route table, even if it's already implicitly associated.
You might do that if you change which table is the main route table, which changes the default for additional new subnets, or any subnets that are not explicitly associated with any other route table.
One way to protect your VPC is to leave the main route table in its original default state (with only the local route), and explicitly associate each new subnet you create with one of the custom route tables you've created.
This ensures that you explicitly control how each subnet routes outbound traffic.
For more information, see Replacing the Main Route Table.Your VPC can have route tables other than the default table.A custom route table is associated with the public subnet.The custom route table has a route over the Internet gateway (the destination is 0.0.0.0/0, and the target is the Internet gateway).
A subnet can only be associated with one route table at a time, but you can associate multiple subnets with the same route table. The main route table controls the routing for all subnets that are not explicitly associated with any other route table.You can add, remove, and modify routes in the main route table.