Even a small dog like a Dachshund would have his own den out in the wild. A place for him to raise his family, get away from predators, get out of the weather, and to feel safe enough with to sleep in. Dachshunds tend to have separation anxiety and training them to see the crate as their den is a very good way to help curb this problem.
The most important thing to keep in mind is that you need to keep everything about the training sessions positive. You should never use his crate as a form of punishment or he might come to view his crate in a negative way, making it all but impossible to train him successfully. Keep the pace slow and steady, but consistent if you want your pup to get used and then enjoy his new "den."
You have a somewhat challenging task ahead of you. Your pup wants to spend as much time as he can with you, on your lap, on the couch next to you, even sleeping on the bed with you (if you let him). While in the wild his desire for a den might take precedence, in your home the desire to be with you is going to make crate training him that much harder.
Rather than think about this type of training as teaching your pup to stay in his crate, there is a better option. Why not make the whole exercise one in which you are training him to see his crate as his new den rather than the wire cage that keeps him from you? By approaching the training from this position, you will find it goes more smoothly and successfully.
Your Dachshund needs a crate that is big enough for him to move around in comfortably. Be sure you don’t buy one that is too big, or he may decide to use one end as his den and the other as his bathroom. Yet at the same time, you don't want one that is too small, or he won't be comfortable in it and will stay out.
To set up your pup's crate and turn it into a den, you need a nice soft piece of carpet that is easy to clean, a doggie bed, a hanging water bottle, and a few chew toys and soft toys for your pup to play with. You may also want to keep a blanket handy to cover the crate and give your pup a nice quiet place to get away from it all and nap.