Why We need vectors?
Vectors represent a set of physical quantities that require both it's magnitude (or length) and direction (spatial orientation) to describe the quantity completely. Take a real life situation as an example. You ask me how many marbles I have in my bag. I say it's 10. Tat"10" is sufficient enough for the answer. Now, ask another question. How far is your house from here? You would probably say about 20 km; not just 20. The additional "km" have to be included in order to specify the solution completely. Now, we ask, how to get to your house? Of course you need the aid of north, south, east, west directions.
Likewise is certain physical quantities. Mentioning just their number alone seems to be out of sense. We call these quantities vectors. These quantities require the direction (represented by arrows) along each coordinate plus the value assumed at some point, represented by the space point.
Is magnetic field a vector?
The answer is a no. It's actually a pseudovector. Consider a straight long current carrying wire and a steady current flowing through that wire. This will generate a magnetic field, with the field lines forming closed loops or concentric rings about the wire. How to specify the direction of a closed loop. The field lines are not even circulating actually. Then how we know that the field lines have a curl?
How magnetic field became a vector?
Do the same experiment as mentioned above. At first, make the current flow upwards through the wire. It will generate a magnetic field at some point near the wire, whose direction can be measured by a compass. Keep the position of the compass fixed (i.e., the distance between the wire and the compass box). The compass needle deflects in a direction of the field line at that point (which we represent by drawing a tangent to the loop at that point). Now reverse the current. Surprisingly, you see that the compass needle deflects in the opposite direction. What does it mean? This means, even though the field lines are not circulating, their direction has to be specified to indicate the direction of flow of current and thereby the force acting on a moving charge. So we assumed tat if a positive current move upwards through a wire, the magnetic field lines curl anti-clockwise. If it flows downwards, the field lines curl clockwise.
This is why we say the magnetic field is a pseudovector.