It depends on the bank whether someone will be allowed to deposit money directly into someone else's bank account or not.
I've had some banks allow someone else to go to the bank and deposit cash into my checking account and others that wouldn't allow it.
You can however have someone go online to their checking account and transfer money from their checking account into yours through online banking.
The other person will need your checking account number and routing number as well as bank details to perform the transaction.