When the 'Intercept' is set to false, then the returned intercept value is 0.
If you run the following:
[betahat_intercept, fitinfo_intercept] = lasso(X , Y , 'Lambda', lambda, 'Intercept', true);
[betahat_nointercept, fitinfo_nointercept] = lasso(X , Y , 'Lambda', lambda, 'Intercept', false);
The output Y can be thought of as following for a single row of data:
y= 500 + w1*x1 + w2*x2+....+w5*x5 +noise
Now, if 'intercept' is set to false,intercept value is 0 and it is adjusted in the weights of w1, w2,..w5.
If 'intercept' is set to true, you get an intercept value of around 500, and the weights are adjusted accordingly.
Refer this for more on lasso.
Hope this helps!