Methanol is a polar solvent; heptane is very non-polar. If you start with methanol as solvent, you can dissolve a little heptane into it; if you keep adding heptane, you reach the solubility limit of the solute heptane in methanol, and the excess heptane floats.
If you start with heptane as solvent, you can dissolve a little bit of solute methanol into it; at its solubility limit, excess methanol will sink.
Now, when you take methanol and heptane in a 1:1 ratio, both solutes have exceeded their solubility in both solvents, and you should wind up with a heptane layer on top, with a little bit of methanol dissolved in it, and a methanol layer below, with a little heptane dissolved in it. In some cases, a metastable intermediate layer forms, but will separate into the upper and lower layers. (Those molecules just can't get it all figured out instantly!)
The phenomenon is called a miscibility gap, where it seems that two liquids go together but only so far. Data on methanol-heptane were not available, but a phase diagram of methanol-cyclohexane is shown below:
The x-axis goes from zero methanol (i.e., all cyclohexane) to all methanol (no cyclohexane). The large central area is the two-phase region. At each extremity, whether methanol-rich or cyclohexane-rich, there is some solubility, which increases if you raise the temperature, until at about 320K (47$^o$C), the mutual solubility equals complete miscibility, and at this temperature and higher, there is only one phase.
A somewhat different plot (of enthalpies of hexane and methanol mixtures) shows the same kind of miscibility gap. Hexane and methanol are completely miscible above about 45$^o$C, but as the temperature is lowered, mixtures with ratio of 1:1 will separate into two phases. Mixtures with only about 20% of the other solvent are stable at room temperature. But from the chart, it would seem to be a good bet that reducing the temperature will make the miscibility gap even wider.