For anyone just wanting to turn the warning off on screen, you can run the command TOGGLEALLSCREENMESSAGES in the unreal console to turn off all messages on screen (to turn them on just run the command again)
EDIT: If you want to disable only the memory warning message, you can do so by setting r.DemotedLocalMemoryWarning to 0 in the console variables editor. Console Variables Editor | Unreal Engine 5.0 Documentation