Check if the file and folder exist and create them