Why do magnetic field lines behave the way they do? I learned that the bar magnet makes a magnetic field and the field lines have a certain shape which kind of resembles two semiovals.
And if we pass current through a conductor then it makes a  magnetic fields and the field lines are in the form of concentric circles around the conductor.
Why? Why do magnetic field lines take the shape that they take? There must be a reason behind it. Why aren't the field lines of a normal bar magnet shaped like the field lines of a conductor carrying electricity? And vice-versa?
I know that it delves very deep into the fundamentals of the working of science, but still...
 A: Physics cannot answer why-questions ultimately. The natural sciences in general try to describe the world in terms of models, which consist of some fundamental objects and their relations. But why the relations are the way they are, cannot be answered by the scientific method. The only statement that physics does make about these fundamental relations is, that they are compatible with our observations and experiments.
So the question "Why do field lines take the shape they take?" cannot be answered finally. We could try answering it as follows: Because the (electro-)magnetic field obeys the Maxwell equations. But that is not a final answer, because we can regress and ask: "Why do the Maxwell equations hold for the electromagnetic field?", we now could answer that question in terms of quantum field theory and argue, that the electromagnetic field is a massless, spin-1 field coupling to a U(1) charge and therefore must obey the Maxwell equations in the appropriate classical limit, but again, this is not a fundamental answer to the why-question. In a way, this question reduces to the question "Why are the physical laws the way they are?" which is quite obviously outside the realm of physics.
As explained, in physics, why-questions can only be answered in reference to some set of fundamental assumptions (axioms). The second question "Why are the field lines of a current carrying wire and a bar magnet different?" is easy to interpret as a question which is to be answered with reference to our model of electromagnetism. Electromagnetism is governed by the Maxwell equations, which can be solved to give the electric and magnetic fields in terms of the current and charge distribution.
In this framework the answer is easy: Because a bar magnet and a current carrying wire have different current distributions. The bar magnet can effectively be modelled by a current perpendicular to the magnetization axis on the surface of the magnet$^1$, the current in the wire is obvious.
Given the Maxwell equations obtaining the shape of the field lines is an exercise in mathematics. One can also obtain them qualitatively by using simple rules, that can be derived from the Maxwell equations (namely, that the circulation of the magnetic field along some line is given by the current through a surface spanned by that line).
Note, that the "effective current" of the bar magnet is very similar to the current in a solenoid, so their magnetic fields will be similar (as noted in the comment by @mikuszefski).

${}^1$ by the way, a proper explanation for the "current distribution" in a permanent magnet is quite complex and requires quantum field theory.
A: This is not an exact answer delving into the fundamentals of the workings of science, however, consider the origin and path of the field lines.
In any sort of magnet, solid or electromagnet (remember an electromagnet is derived from the magnetic field created by movement of charge), the field lines pass through the magnet itself. It is perhaps just the most logical path for field lines 'moving towards' the opposite pole to be eccentric, not uniformly circular(?).
The movement of charge however, (reiterating, I don't know the science behind it, yet if I could accurately explain magnetism I dare say I would be a very popular bloke!) creates a uniform charge around it, not through it. And consider the creation of a solenoid by coiled wire. Maybe they aren't as different as we think, as with one set of lines we can create another? Perhaps the magnetic field created by each individual wire causes the eccentricity in the field lines of a solenoid? Not only causing the internal direction of charge, but also 'attraction' towards the internal structure?
I would love to hear some legitimate science behind this, though!
A: The magnetic field of a straight wire, and a normal bar magnet does not look similar, because of their dipole moments.
Consider the vector of magnetic dipole moment of a bar magnet, and call it $\vec \mu$. If we find a current carrying wire (or loop or random shape) which has the same magnetic dipole moment, then their magnetic field will resemble a bar magnet. Read up on magnetic moment.
To give you a small idea, the field of a solenoid is quite similar to a bar magnet. They both have the same direction of $\vec \mu$, and if we can also find the same magnitude, their magnetic field strengths should also be same. However, I recommend you search up on these terms and understand yourself. I may be wrong.
A: 
Why do magnetic field lines behave the way they do?

Because they map out "the state of space". See Einstein's 1929 history of field theory where he said this: "The two types of field are causally linked in this theory, but still not fused to an identity. It can, however, scarcely be imagined that empty space has conditions or states of two essentially different kinds". A field is a state of space. The state of space around your magnet is not the same as the state of space around your apple.  

So I learned that the bar magnet makes a magnetic field and the field lines have a certain shape which kinda resembles 2 semi-ovals.

Yes. The magnetic field of a bar magnet is like that of a solenoid. See this depiction from Rod Nave's hyperphysics:

If you reduce the number of coils in the solenoid, it's like shortening your bar magnet. Keep doing this and eventually you get to a current loop, where the magnetic field tends to be drawn like this: 
 

And if we pass current through a conductor then it makes a magnetic fields and the field lines are in the form of concentric circles around the conductor.

Yes. You can draw it like this: 

The magnetic field lines map out the state of space, which determines how an electron will move. If you throw it from right to left it into the current, it will move in a clockwise near-circular fashion. Note though that a positron will move anticlockwise. This is because "it takes two to tango". The motion of the particle depends on the space its in, and on the particle.   

My question is why? Why do magnetic field lines take the shape that they take? There must be a reason behind it. 

There is. It's because the magnetic field around the straight wire has a rotational symmetry, and it gets weaker with distance. So we draw concentric circles, with bigger and bigger gaps between them. The charged particle moves  round a larger-diameter near-circular path when it's further from the wire.    

Why aren't the field lines of a normal bar magnet shaped like the field lines of a conductor carrying electricity? And vice-versa?

Because they're like the field lines of the current loop instead. To go from the straight wire to the loop, you just bend it round. Remember the depictions aren't perfect. The magnetic field around the wire has a cylindrical disposition, the field around the current loop has a toroidal disposition. To go from one to the other you just bend the wire. Maybe what would help is if I drew two sets of concentric circles. Bend this into a loop:   
 
and you should be able to see why the magnetic field looks like it does in the second picture above. 

Please explain it to me..i know that it delves very deep into the fundamentals of the working of science but still...please tell me the reason if anyone knows it.

I know all about magnetism Marty. It's all pretty simple when you understand it. Unfortunately, some people seem to prefer mystery. Sorry about that. 
