A multiscale computational framework for nonlocal discrete element models: reduction of spurious effects at interfaces