The Federal Reserve (often called the Fed) is allowed to be independent because its job is to make sure that the economy is strong and stable in the long run. Politicians are often not very interested in the long run. They are worried about the short term. This is particularly true when it gets closer to election time. Politicians want to do things that will get them reelected, not things that will be good for the economy in the long term.
If the Federal Reserve were to be controlled by politicians, it would no longer be able to do what is best for the economy in the long term. Instead, it would have to do what politicians want to spur the economy in the short term, regardless of the long-term consequences. For this reason, it is best that the Fed should be independent of political control.