The Federal Reserve raised interest rates on Wednesday, with the Fed chair saying that the move is necessary to fight inflation.