To crochet a basic beanie you will need yarn and a crochet hook. You can use anything from crochet thread to super bulky yarn with appropriate hook for it. Then you will need to decide which stitch you want to crochet your beanie with. Single crochet will give you a nice, tight material and it will be easier to control the size. My favorite is the half double crochet. You get the convenience of a small stitch, yet slightly bigger than a single crochet. You could go double crochet, but then you get into a more loose fabric which might let in more cold air. Still, it's your decision.
You want to start off with a small beginning ring, or as I like to do, crochet into the first chain of your beginning chain. It should be large enough to hold your first round of stitches and will give you the smallest crown 'hole'. For single crochet hats chain 2, for half double also chain 2 and for double crochet chain four, with the ch-3 being your first stitch, you will need 11 more.
Your first round will depend on which stitch you select. Single crochets should only need a starting number of six, half double crochets need a starting number of eight and double crochets need a starting number of twelve.
Your next rounds will consist of increasing by your starting number each time, evenly around, until your crown is large enough. This will depend on if the hat is for a preemie, a newborn, a baby, a toddler, a child, a teen or an adult. Your best bet here would be to measure the head that the hat is meant for, and then crochet a circle that has a diameter of roughly one quarter that. My head is 22” around and I usually make my crown to about 6” diameter. For a beret-style hat, make the crown roughly half the measurement of the head it is meant for.
Then you will crochet in even rounds until the hat is the right length. That's just about it. Easy-peasy.
Now if you want a slouchy hat, you can simply crochet around until it's slouchy enough before ending off. For a beret-style you would make an even bigger starting circle, crochet evenly for four to six rounds and then decrease (Using the beginning number of stitches you started with-6/8/12/etc) until the hat is the right size. Here you might want to attach a single crochet ribbing band.
To attach a ribbing band, you will want to switch out your hook for another that is at least two sizes smaller than the one you were using. In other words, if you were using a size K hook, then you would switch to a size I hook. Then you will chain a length for however wide you want your ribbing to be, plus one to turn. Then single crochet into the second chain from hook and all other chains. Then you will slip stitch into the next two stitches of your hat and turn. You will now work in the back loops only of your band. Skip the two slip stitches and single crochet into each single crochet of your band. Chain one and turn. Single crochet back up to your hat and slip stitch into the next two stitches and turn. Got the pattern? Do this all the way around the hat, until you reach the beginning of the band and end up at the outside edge of the band. Slip stitch the last row of the band to the free loops of the beginning chain and you're done!
Really, it's all up to you what you want to do with your hats, I'm just giving some basic guidelines to get you started.