@Shashant Panwar
If you click on the Hive Service --> Config you can see option to increase Hiveserver2 Heap Size and Client Heap Size.
Please increase them in order to overcome the issue.
Were as in Hive CLI it connect directly to Hive Metastore but for beeline it has it's own metastore inside Hiveserver2. Hoep this helps you.