The FBI Director is a position within the executive branch of the US Government, thus the President is able to dismiss him like any other executive branch official.
There's no exact process and the President just needs to announce his intent and in Comey's case, he wrote a letter to him.
Under the Constitution, the FBI Director is an executive branch official and can be removed if needed. But only in one instance since 1908, after the FBI and its predecessor agency were formed, has a President removed an FBI Director from office.
The President has the power to appoint or to dismiss FBI Directors since 1968, as seen in this CRS report.
There are no statutory conditions on the President’s authority to remove the FBI Director.
[ ... ]
Accordingly, the principles discussed above establish that the President may remove the Director of the FBI at will, given that the “power of removal [is] incident to the power to remove.”
[ ... ]
It should also be noted that during Senate consideration of the 1976 measure, Senators Byrd and Hruska emphasized several times that “there is no limitation on the constitutional power of the President to remove the FBI Director from office within the 10-year term. The Director would be subject to dismissal by the President as are all purely executive officers.”
So, there are no limitations as to dismissing an FBI Director as they are part of the executive branch that the President helms.