You need to remove the front wheel and measure both the inside and outside, edge to edge. Now 5 inches is 125 mm, So my guess is you have 100-110 mm wide forks. If you have 100mm, everything fits.
At 110mm and higher, it gets dicey. Sure, you can turn the washers around and put the wide ones on the inside. You can also add a few extra washers, but you're stuck if the the axle of the motor isn't long enough to for the axle nuts to fit.
For example, I'm looking at a print of a Bafang SWXK front motor. Axle width is 140 mm, which is 5.5 inches. Might be too narrow. There are other motors. Some show 150 mm for axle length. Others are less than 140mm. If you still have your motor, maybe you can check it for the fit of the nuts.
If your fork is steel, it's no problem to skip the spacers and squeeze it 10mm. I recall using a scissors jack to spread a steel frame about 1/2 inch to fit a motor, Meanwhile, the front fork had gotten squashed in the shipping box and was about a half inch too narrow for the wheel, But that was steel too. I just bent it back.
If the fork or frame is alloy, you cannot bend it it. If it doesn't break right there, it will break later. Anyway, I wouldn't do it.