Why don't we use an alkyl halide directly in Gabriel Phthalimide Synthesis?

In Gabriel Phthalimide Synthesis, why do we use $\ce{KOH}$ in first step rather than directly adding an alkyl halide?


![enter image description here](https://i.stack.imgur.com/2e37Y.png)


![enter image description here](https://i.stack.imgur.com/ainpB.png)




It is used to make the conjugate base of the imide which is far more nucleophilic than the imide itself, but not too much to attack another molecule of the alkyl halide.


 3

The goal is to make a primary alkylamine without causing polyalkylation. If you do not activate the pthalimide nitrogen with a base, you have a highly delocaled lone pair on the nitrogen. At best, you get an Sn1 reaction, however that will not give a primary amine as loss of the halide (if you can force it to go) will undergo Wagner-Meerwein rearrangement (hydride shift) to give a secondary or tertiary amine. 
This is the point of the Gabriel phthalimide synthesis.


 1