With Messi's positioning I think the best system for Barca would be ten Hag's 4-2-1-3 where Messi can have a free role and make his runs forward to the box like Donny van de Beek without screwing Barca over by playing with one less winger.
You also get to play Frenkie in his best position. In a flexible double pivot where he got the freedom to roam.
You get two wingers who can create width and win 1v1 and create from the flanks. You get one CF to occupy the CBs.
What it means is less control, but if you want more control you simply sub out the RW and put Messi there and bring in a midfielder like Arthur.
Something like this:
ter Stegen
Emerson - Athletic CB - CB - Alba
Camavinga - de Jong
Messi
Dembele/Griezmann - CF - Neymar
Suddenly a way faster, way more athletic team that's able to press better, physical double pivot with Fdj and Camavinga and a team that doesn't need Messi to save the way for it to work since it's more balanced by actually playing two players on the flank and a proper CF.
Won't happen IRL, but at least I can do this in FM 20