The person above you is incorrect, the highest positions are nominated by the president and confirmed by the senate. However, the Fed does work somewhat independently of the government and does work directly with banks.
This is all done to ensure that the Fed is somewhat apolitical and only focused on its goals of "maximizing employment, stabilizing prices, and moderating long-term interest rates"
This independence is part of why Trump hates the Fed, because they won't give into his demands (as they shouldn't cause Trump is blowing up the economy).