You can only have immutable functions in a generated field. The problem here is not the ST_X or ST_Y function, but the concatenation. For wathever reason, concatenation in postgresql is stable and not immutable. You can see the definition of a function doing this:
The simplest way to do what you want should be by creating a concatenation function which is immutable, by doing this (you need top priviledges to do this so you probably need to login as postgres to your db):
CREATE OR REPLACE FUNCTION immutable_concat(VARIADIC "any")
RETURNS text AS 'text_concat'
LANGUAGE internal IMMUTABLE;
Then you should be able to do this (untested):
ALTER TBALE poi ADD COLUMN
lonlat varchar GENERATED ALWAYS AS (
immutable_concat(ST_X(the_geom), ', ', ST_Y(the_geom))
You should use this immutable version carefully tho, because it can apparently change the output depending of the type of argument in input, especially with date (see for exemple https://stackoverflow.com/questions/54372666/create-an-immutable-clone-of-concat-ws). This function is originally not immutable for a reason. But in your case there shouldn't be any problem.