How to create drop down while the menu structure is in array type?
I have found some possible answers related to your solution.

SOLUTION 1:

The main menu in Bartik only displays the first level. Since it's hardcoded in page.tpl.php there's nothing you can do about it.

Here's how to get the menu to work properly:


In your theme settings (admin/appearance/settings/bartik) disable "Main menu".
Go to admin/structure/block and add the "Main Menu" block to the header region (or wherever you want it).


Alternatively, you can also check out the excellent Menu Block module, which generates extra customizable blocks (1st level, 2nd level, etc) for each menu.

SOLUTION 2:

There are some useful resources that may help you to solve your problem.


How to create a drop down menu in bartik theme
Drupal 7 + Bartik + Dropdown for Main Menu Children
Add drop down menu support to Bartik
Drupal Responsive Bartik Theme with Dropdown Menus