Box Inc beat quarterly sales expectations on Tuesday as remote work and learning during the COVID-19 pandemic drove demand for its file-sharing services.