Trump seems intent on keeping the allies he has in Congress rather then consolidating ideological control. Graham was against Trump in 2016 but ever since his first term he has sucked up to him hard but there is a good chance he is merely acting as an opportunist.
The Senator notably supported Trump's election recount efforts in 2020, said that Joe Biden and Kamala Harris are lawfully elected after the events of January 6, 2021, voted against Trump's second impeachment and was against the January 6 commission. He has also criticized Trump for not supporting a federal abortion ban and said it was "a mistake" for Trump to pardon criminal defendants who pleaded guilty to or were convicted of violent crimes during the events of January 6 but at the same time he later defended Trump's decision to fire the 17 Inspectors General early into his second term.
He seems quite "fair-weather" with his political support at times to say the least.
Here is Graham getting booed in his own home state a few years ago and then immediately being defended by Trump: