> max_docs is not working in 6.5.4 but its working in 7.3.2 when we are using delete_by_query`
I think this parameter was added in Elasticsearch 7.3, so would not be available in earlier versions.
even I am getting issues if I use size which is supported in older versions
You haven't given us any information on what issues you are seeing, so sharing the problem you have would be helpful.
Please also note that 6.5 is EOL, you should upgrade ASAP.