Can language models handle recursively nested grammatical structures? A case study on comparing models and humans