If she's doing that she's either not fully house trained or she's marking.
Either way you need to be watching her at all times because she can't be trusted when you're not watching. Every time she gets away with it she learns that it's ok.
If necessary you can leash or tether her while you're there so she can't wander off out of your site.
Do it like you would housetraining a young puppy. Don't punish after you find an accident because she won't understand. You'll need to catch her in the act and immediately stop her and take her outside.
You also need to completely clean the areas with a urine remover so that there is no smell to cause her to pee there or mark (even if YOU can't smell it she might be able to).
At 8 months old you're perhaps trusting her to be housetrained too soon. A lot of dogs aren't completely housetrained by that age and if you slack off and allow her to have accidents while you're not paying attention you will have to start over again.