Generating bigger block world

I am new to Unity3D but have experience with C#. A have gone thrue few toutrials for unity. And now made simple “Minecraft” style cubes. Generated 10x10x10 world with cubes and thath you can build and delete blocks. Now i want to make this ground bigger probably size 500x500x100 but with such basic i have made:

    for (int x = 0; x < 10; x++)
    {
        for (int y = 0; y > -10; y--)
        {
            for (int z = 0; z < 10; z++)
            {
                Instantiate(prefab, new Vector3(x,y,z), Quaternion.identity);

            }
        }
    }

Will probably burn my computer if i try a size like 500x500x100 ^^ So i am looking for your opinions how to make generator for bigger world optimized etc to it will be able to generate big world. I am not looking for any hills generating etc just flat cube land.

Thanks!

Generate chunks of meshes instead of instantiating individual objects. Don’t generate faces that can’t be seen.
You can also check this “question” out for some pointers.