Deck construction and tuning is a big part of the fun (and the skill) in Magic. Becoming an expert deckbuilder can be a multiyear learning, not something that can be given in a StackExchange answer. But as someone who did spend those years (lots of "limited" competition and a decent amount of "constructed" format competition) I'll offer some principles to get you started:
A deck is a subset of the available cards that you choose to play, not the collection itself. You choose which cards to include in a deck in order to
a) meet whatever rules apply to your format (e.g. a 40 or 60 card minimum; rules on how many copies of a particular card can be included; what sets are eligible, etc.). These can be formal tournament rules or just whatever you and your circle of players think will be fun.
b) WIN! :)
Winning implies you have a strategy to actually win, e.g. "I will deal very fast damage to kill my opponent before they can even get set up" or "I will hit my opponent with creatures they cannot block" or "I will play a defensive battle and win with a late, game-breaking play." Obviously not all strategies are created equal, and the real fun is in the interactions between strategies. For example, a deck that concentrates on dealing damage with early fast creatures can be very effective against a deck that is slow to get defenses up, but tends to struggle against a medium-speed deck full of larger creatures. This implies that there is no one winning strategy, and that even selecting what strategy may depend in part on what you expect to face. OK, that's how you plan to win.
c) You also want to not lose. Yes, this is different from the strategy to win.
Not losing (more than necessary) means two things, both more tactical. First, you want the deck to be efficient and repeatable in its execution of the strategy. That means things like ensuring you generally have the mana to play your spells, but not more mana than you need (dead cards in your hand). There are general guidelines for these things (e.g. search up "mana curve"), and you will also develop a feel, but don't hesitate to just play out a bunch of hands solo and see how it's working.
The second element of not losing is potentially including cards that don't directly feed the primary strategy, but make the deck more resilient to opposing strategies. For example, if you are playing small weenie creatures maybe you need to add just 1-2 evasion creatures to give you a chance once the opponent gets good blockers in place. Or if you are playing a combo deck, maybe you need some defense to give yourself time to draw the combo. In general, I find it best to build the pure strategy deck first, and only swap in a few tactical cards like this if you absolutely need them. The difference in effectiveness between a pure full-on assault and a "90% assault, 10% what if" can be huge.
This is just a few thoughts to get you started. Pick how you want to win, do sample draws/plays to balance mechanical aspects, and then ultimately judge the deck by how it performs in real matches. And have fun!