Epoxides can open up in two different ways.
To add a nucleophile to the less substituted side of an epoxide, use basic conditions. This is done in #2 below.
To add a nucleophile to the more substituted side of an epoxide, use acidic conditions. This is done is #1 below.
Why do the conditions matter? Epoxides have two electrophilic carbons. Normally nucleophiles will preferentially attack the less substituted carbon, as they do in SN2 reactions. Recall that SN2 reactions usually happen with strong nucleophiles- that is, negative charges (basic conditions).
When an epoxide reacts under acidic conditions, the transition state has carbocation character, and so it's sort of like an SN1 reaction. That is, instead of less substituted carbons being favored due to less steric bulk, more substituted carbons are favored do to a more stable carbocation. So acidic conditions cause an epoxide to open up on the more substituted side.