These yarns are usually called thick-and-thin yarns, or occasionally slubby yarns, though the latter usually means the yarn is largely of one thickness with frequent, irregular ‘bobbly’ bits.
Thick-and-thin yarns come in various weights from thread to super-bulky. You can knit any pattern that uses the same weight and gauge as your thick-and-thin yarn. This is because you will be using the appropriate size of needle. The ‘thin’ bits might look a little lacey, or the ‘thick’ bits may look bunched up, but your fabric will even itself out over all.
Thick-and-thin yarns are particularly good at injecting life and movement into otherwise dull and plain knitting. They transform boring stretches of stockinette or garter stitch into an interesting-looking fabric. Some people love the rustic, homespun, home-made look they give to otherwise ordinary garments, and they certainly liven up a basic scarf or cowl. They’re also much loved by independent hand-dyers for their more exotic variegated dyes, so you may well have a virtually unique item at the end of your knitting.