I am using Adobe Illustrator CS6. My goal is to make 40 A4 artboards for print all in a single project, but when I exit the program and open it again, they get replaced with guides. Is there are way to let Illustrator keep your artboards? If I had to make small adjustments before printing, I would need to waste extra time redrawing each artboard again.
I don't have access to CS6 any more so I can't check this for sure, however it sounds like you might be saving your documents in a legacy format (before CS6) which might not support multiple art-boards properly, or in the same way that CS6 does.
When you save the AI file, make sure you choose the correct version, i.e. to save in Illustrator CS6 format*
If try to save a multiple art-board document from Illustrator CC to CS3 for example, I can reproduce the problem. Artboards are indeed converted to guides when reopening the file.
*This screenshot is from Illustrator CC, but it should be similar in CS6.
Sounds like you might be doing the wrong thing. AI does not just replace artboards with guides, there's no such thing :) Make sure you read the official documentation and properly use the Arboards feature: https://helpx.adobe.com/illustrator/using/using-multiple-artboards.html