I assume it is a student exercise, not intended for a real product.
Do you have real hardware or are you trying to simulate?
What crystal frequency are you using?
A few things from a quick look.
Value of R5, 470ohm, is far too high. With 70ohm load that is not going to work.
I assume that resistor is intended to prevent the mosfet burning when the software
turn it on for too long.
Perhaps intended to be 4.7ohm resistor with a high power rating. If you use a bench
power supply with a current limit of 1amp then you could a 5watt resistor, or combine
some smaller resistors eg ten 0.5watt 47ohm in parallel.
If you have long wires from the 12volt psu, you will want a smoothing capacitor near
L1 and the mosfet. It will need good layout for the parts of the circuit with fast switching.
It may be easier to get started if you make COUT a much higher value. 12.5uF is a bit low.
Your output current is 0.26A, when COUT is holding up the output voltage between pulses,
we can calulate that the voltage will drop 1volt (eg 18volt to 17volt) in 0.00005 seconds
You will need a fairly fast switching rate to not have huge output ripple with cout=12.5uF
The 16f877 datasheet suggest feeding an ADC pin from a source impedance of 2500ohm max,
source impedance of voltage divider with 138K resistor is much higher.