Before I mention some issues, my recommendation will be that you switch to a dedicated boost converter IC. Personally, I wouldn't recommend building a uC controlled boost converter (more on this later)
Now, coming to the issues/recommendations.
You are switching at 1Mhz frequency. Using a MOSFET at high frequencies is a better option than BJT. You can refer to this post When is a MOSFET more appropriate as a switch than a BJT?. Coming to MOSFET selection, there are MOSFETs which turn at low Vgs ~2-2.5V, even less and have peak current capability of around 2-3A. Since there are lots of MOS devices around and your procurement depends on the component availability in your area, I would suggest you do a quick search on https://www.mouser.com, use their search tool and find out which part suits you the best.
One drawback in your circuit is, there is no reverse voltage protection at the output side. Since you will be connecting a motor at the output, back emf will be generated when motor will be stopped or its speed will be reduced. In such a case, the reverse voltage will flow all the way from the output to your MCU feedback pin via the R6-R8 feedback network. Having a zener at the feedback pin is a good solution but not a great solution because zener doesn't protect the electrolytic capacitor C11 (22u) from the back emf. So you need to protect the MCU as well as the capacitors. A schottky diode at the output rail can achieve both tasks. Still, I wouldnt say this is a great solution either because of constant power loss in the schottky diode at output.
Your circuit will work fine when there's a load at the output. But when load isn't present, the duty cycle may increase rapidly to a high value, boosting the output voltage tremendously. The output capacitors will have to endure a very high boosted voltage which can potentially damage them. Moreover, this high voltage can generate a higher feedback voltage (>2v) which can possibly damage your MCU too. So either take care of this problem in software or include a dummy load at the output to avoid this scenario. You somehow have to implement a circuit or a code which prevents the output voltage to rise beyond 12v,
Still the above mentioned fixes are very crude fixes and not recommended for a reliable design. I will not go deep further into the design issues because if you are considering long term reliability, there are a lot of things your circuit should take care of (compensation, ADC drift, temperature range, supply fluctuations, noise, protection etc). The more issues you encounter, the more you have to bang your head solving them. Plus, you have to work on the hardware as well as the software which will further increase your development time. Don't just look at the entire project from a cost reduction perspective. Consider the efforts involved in development, debugging, verification, reliability and PCB fabrication, too.
Now coming to my recommendation. A dedicated boost IC will have all the required blocks inbuilt in them. Basically, whatever hard work you are doing in software, that is done by these inbuilt blocks easily and reliably. I have personally worked with UC3843 IC for a 600W boost converter with CC-CV. I know UC3843 is a very old IC, but despite its age, the support on forums is still amazing.
With a dedicated boost IC, you get a lot of features for half the cost of a uC. Features like Over voltage, over current, drift, compensation, UVLO, current limiting, output adjustment etc. are all offered by a lot of boost converter IC these days. Being a decade old IC, UC3843 provides these features, so I can bet present day ICs offer more than what 3843 does, that too at a fraction of its price. Moreover, you will get verified reference designs, post development support on forums, PCB layout, guidelines, performance characteristics and so on.
From an engineering point of view, you are wasting valuable functionalities of a uC by using it only to generate pulses. Instead, let the boost IC do the task of dc-dc conversion. Meanwhile, you can use your uC to monitor the state of the boost converter.
Hope this helps! :)