Why does enabling LPIM cause Error 701 even when there is free physical memory outside SQL Server?'
So did you go back to earlier error logs to see there were any messages about SQL Server being swapped out?
I would guess that for some reason Windows is not prepared to give SQL Server physical memory. Yes, there might be free memory, but Windows cannot reclaim that physical memory, since SQL Server's memory cannot be swapped out when it has LPIM.
Does SQL Server allocate all memory up to
max server memoryfor buffer pool?
It might, depending on the queries executing on the system. That is, SQL Server does not automatically allocate memory up to "Max server memory", only if there is a need to. But once it has allocated that much memory, it will only release memory, if Windows signals that there is memory pressure.
Does workspace memory come from the configured
max server memoryor from OS free memory?
I am not sure what workspace memory you have in mind here.
How does LPIM affect memory grants and overall memory management?
I can't see that LPIM directly affects memory grant.